Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Scoping of Variables
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00011488
Message ID:
00011697
Views:
45
>>>
>
>I have read all related map messages and I think we have some misunderstanding. Actually, If we decided to use property of calling form as a place to store 'variables' we DON'T NEED to send them as parameters. Surely this will work nice if called form is modal. This case just create array-property in first 'calling' form, fill it with some values and then use this property inside all events/methods of next modal 'called' form.

Thanks Edward, I know what you are saying, and that part works fine in
my form, let me explain again waht I need to do, lets say that I have
a main program like:

*Main Program
PRIVATE aMyArray
DIMENSION aMyArray(1)
aMyArray(1)='Apple'

SET UDFPARMS TO REFERENCE
DO FORM oMyForm WITH aMyArray

in the init event of my oMyform I have:
PARAMETERS apArray
...code,code and code
and then in the click event of the buttom that close my form I do this:

DIMENSION apArray(2)
apArray(1)='Tangerine'
apArray(2)='Orange'
RELEASE THISFORM

and when I return to the main program, guess what?, aMyArray only
have one value and this is 'Apple', the original one !!!, I have found
that this doesn't happen if you send an array by reference to a procedure
or function, but in forms it just don't work.
Like somebody said in our lovely "Microsoft support department",
It is not a bug, is a "feature".
Luis Guzman, MCP
"The only glory most of us have to hope for
is the glory of being normal." Katherine Fulleton Gerould
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform