Can someone tell me if Progress has what I know as MACRO substitution. Here is the explanation per Visual FoxPro:
You can replace names with variables by using macro substitution. To use macro substitution, place an ampersand (&) before the variable to tell Visual FoxPro to use the value of the variable as a name, and use a period (.) to end the macro substitution expression.
For example, the following print statement produces “FoxPro”:
x = "Fox"
? "&x.Pro" <-------- "?" is print to screen.
I am wanting to do something similar in Progress. Example below:
***********************************************
MyString = "By credit-limit"
Instead of...
FOR EACH customer BY credit-limit:
Use variable...
FOR EACH customer MyString:
***********************************************
I know that I could use &GLOBAL-DEFINE but this is pre-processor substitution and I need to dynamically define the "MyString" based on some runtime event.
Thanks in advance...
Bill Wester
RoBAND Corporation
You can replace names with variables by using macro substitution. To use macro substitution, place an ampersand (&) before the variable to tell Visual FoxPro to use the value of the variable as a name, and use a period (.) to end the macro substitution expression.
For example, the following print statement produces “FoxPro”:
x = "Fox"
? "&x.Pro" <-------- "?" is print to screen.
I am wanting to do something similar in Progress. Example below:
***********************************************
MyString = "By credit-limit"
Instead of...
FOR EACH customer BY credit-limit:
Use variable...
FOR EACH customer MyString:
***********************************************
I know that I could use &GLOBAL-DEFINE but this is pre-processor substitution and I need to dynamically define the "MyString" based on some runtime event.
Thanks in advance...
Bill Wester
RoBAND Corporation