Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
What is PARAMETERS?
Message
From
23/08/2001 20:01:59
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00548260
Message ID:
00548400
Views:
8
...and, to round it all out, there are the parameters indicated within parentheses after the name on a FUNCTION statement. These are implicitly LOCAL too,although I couldn't find this documented in the (VFP7) Help for "FUNCTION Command".


>The LOCAL and LPARAMETERS command both declare variables as local. The difference is that LOCAL command initialazied it's variables to .F. and you change them by assigning new values. The variables declared in the LPARAMETERS commands get data from a calling program when a procedure, function, or method is called. You can assign values to them too but calling program would see those changes only if the parameters passed in by reference.
>
>>Is, in example, the LOCAL variable same as LPARAMETERS?
>>
>>
>>>>What is difference betwen variables (LOCAL, PRIVATE, PUBLIC) and PARAMETERS?
>>>The Local variables and variable arrays can be used and modified only within the procedure or function in which they are created. They are initialized to false (.F.).
>>>The Private command hides specified variables or arrays that were defined in a calling program from the current program. It doesn't create variables. The private variables are visible within the procedure or function in which they are created and all called progam/functions.
>>>The public variables in general all visible thru the application an initialized to false (.F.).
>>>The PARAMETERS statement declares parameters as PRIVATE.
>>>The LPARAMETERS statement declares parameters as LOCAL.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform