Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Macro Substitution
Message
From
29/05/1998 18:05:02
 
 
To
22/05/1998 16:52:07
General information
Forum:
Visual Basic
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00101311
Message ID:
00103270
Views:
20
>Is there a way to do this in Visual Basic:
>
>You have to Variables Va and Vb
>Va=100
>Vb=20
>
>In your database you have formulas using this constants
>
>field1 = "Va*20/100"
>field2 = "(Va*20/100) + Vb"
>Field3 = "Field1 + 10"
>
>When you run your program you want to change the variables and save the result in another database
>
>R1 = (Field1) = 20
>R2 = (Field2) = 40
>R3 = (Field3) = 30

One big mistake in Visual Basic 5, there is no macro substitution - worst, no Evaluate() function. Macro substitution is kinda not suggested to use. However, an Evaluate() function is certainly a must in each language. You will find that function in several environment but not in Visual Basic.

However, there is a trick to do it with formulas. But, with formulas only.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Reply
Map
View

Click here to load this message in the networking platform