Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using #defined constant as string
Message
From
21/11/2005 13:45:08
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Using #defined constant as string
Environment versions
Visual FoxPro:
VFP 9
Miscellaneous
Thread ID:
01070862
Message ID:
01070862
Views:
53
I use #define constant in SELECT statement and as character string like:
CREATE CURSOR invoice ( price N(12,2), quantity N(2), packing N(2))
#define d_quantity quantity*packing
#define d_sum price*d_quantity

SELECT d_sum FROM invoice

TEXT TO ctxt noshow
  d_sum
  ENDTEXT
MESSAGEBOX('Sum formula is: '+ctxt)
This requires separate memory variable using TEXT command for each #define

How to force MESSAGEBOX() to show d_sum value as character string without using TEXT command?
Andrus
Next
Reply
Map
View

Click here to load this message in the networking platform