Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Local array won't work
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00487664
Message ID:
00487771
Views:
8
>>>doesn't the "LOCAL ARRAY" definition do the same as "DIMENSION"?
>>
>>
>>DIMENSION creates a PRIVATE array.
>
>Nope, not always. Consider the following:
* MyPrg1.prg
>LOCAL a_anyarray
>DIMENSION a_anyarray[1]
>a_anyarray = "Hi there!"
>DO MyPrg2
>RETURN
>
>* MyPrg2.prg
>? a_anyarray[1] && Generates "File a_anyarray.prg does not exist" error.
>RETURN
However, take out the LOCAL statement and it is private because its scope hasn't been specified.


Right...that's what I was saying.
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform