Solved

How can I "eval" in VB5?

Posted on 1998-04-01
5
287 Views
Last Modified: 2008-02-01
I am writing a mathematical analysis program that needs to do "on-the-fly" evaluation of several lines of code which the user will input (more complicated than a simple calculator).  Is there an equivalent of the Perl "eval" statement that will let me avoid recompiling the program every time the analysis formulae change or how would I do this?  (I would guess this issue might have been addressed before in one of the 3500+ archived questions.  If so, is there an Experts-Exchange search engine that will let me avoid manually parsing the entire database?)
0
Comment
Question by:tuinstra
  • 2
  • 2
5 Comments
 

Author Comment

by:tuinstra
ID: 1460190
(For clarification, I am aware of the "Eval-O-Matic" module commercially available.  To my knowledge, it does not evaluate code, simply expressions, so it won't work.)
0
 
LVL 1

Accepted Solution

by:
lbk earned 200 total points
ID: 1460191
Try www.saxsoft.com for a stripped down VBA ocx, that allows you to offer a visual basic macro language to your customers. They have a 45-day trial which I downloaded. I was impressed.
$995, no royalties

I had the same problem, so I wrote my own calculator. It's got variables, you can add your own functions per OLE, implement it per OLE. It's pretty fancy. If you want more info, write me. lbk@ionet.net Other than that, I don't know of anything that would do the trick for you. If you could give me a reference to some info about Eval-O-Matric, that would be great.
Good luck
0
 
LVL 6

Expert Comment

by:clifABB
ID: 1460192
Videosoft (www.videosoft.com) offers VSOCX which contains an AWK control that contains an expression evaluator.
It's $149 USD and a demo is available from them.
0
 

Author Comment

by:tuinstra
ID: 1460193
Fair enough.  This is about what I figured.  Here are the URL's for a couple commercially available "eval" modules.
http://www.aivosto.com/eval.html
http://www.vbonline.com/vbonline/cafe/eom/
I think I will look first into the less elegant, but free possibility of trying to make VB call the (WinNT/95 build of the) Perl interpreter, pass it some parameters and snag the results.  In UNIX this is eminently doable -- in Windows I'm not so sure, but I intend to try.  If not, I'll probably contact you about your module.  Thanks, Max
0
 
LVL 1

Expert Comment

by:lbk
ID: 1460194
I hope you find what you're looking for. Otherwise, I'll hear from you..
Thanks 2
Lukas
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Suggested Solutions

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now