Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP Bug??
Message
 
 
To
15/03/2003 22:28:54
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00766256
Message ID:
00766269
Views:
36
Bob,

It's not a bug but a feature that exists in Foxpro since I can remember (Fox 2.x). Foxpro does macro substitution in string literals if macro variable value is a string. I agree, that string literals shoudn't be affected by macro substitution but they are.

>FoxPro seems to have a problem during a variable assignment when the name of a local (or global) variable is contained within a string literal with a preceding ampersand and succeeding space. "someValue &localVarName someOtherValue"
>
>Can somebody explain??
>
>
>Code summary:
>&& Sample of problem
>Test()
>
>FUNCTION Test()
>  LOCAL localVarName
>  localVarName = ""
>  localVarName = "someValue &localVarName someOtherValue"
> ?localvarName && Possible unexpected results. See detailed code below.
>ENDFUNC
>
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform