Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Parameter question
Message
From
04/12/1998 15:49:08
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00164251
Message ID:
00164263
Views:
18
>Proc1 passes variable1 to proc2 as parameter by value. Variable1 is declared public in main. Proc2 calls many other procs. One of those procs changes the value of variable1. Shortly after I (think it is when I actually return to proc2), get a VFP error messagebox "variable1 not found". If i go into the debugger, variable1 is no longer declared. What is up with that? Thought since the variable1 is passed by value that proc2 would have a copy and would not care if variable1 is then changed, but obviously I am wrong.
>
>Are my assumptions correct, anyone have any experiences with this?
>
>Thanks - Brenda
Brenda,
As long as call by value you're right. Might it be you're calling ... with Variable1 thus variable is passed by reference ?
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Reply
Map
View

Click here to load this message in the networking platform