I have an application that needs to allow users to write expressions similar to excel:
(H1 + (D1 / C3)) * I8
and more complex things like
If(H1 = \'True
I've got a counter-example of how not to do it: Will o’ the Wisp (since this is my own code I feel confident criticizing it).
What's good about the Code?
Turtle graphics http://i3.codeplex.com/Project/Download/FileDownload.aspx?ProjectName=wisp&DownloadId=34823
What's bad about the code?
Have a look at this open source project:
Excel Financial Functions
Check out ANTLR. You define a language syntax, test it using a GUI tool and generate source code in a variety of languages. Open Source.