Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Call a procedure like a method syntax
Message
From
21/04/2009 21:45:03
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01395833
Message ID:
01395852
Views:
77
Check you link. It did not work correctly when clicking on it from UT, but I ddi find it...

http://www.berezniker.com/content/pages/visual-foxpro/difference-between-function-and-procedure-statements

(your link has a space between "and" and "procedure" instead of a dash)


>It mostly comes down to personal preferences unless you need a return value which only UDF call can return. I prefer to use UDF calls. See Difference between FUNCTION and PROCEDURE statements for more info.
>
>>I have several procedures in a .prg file that I call in various places in my form methods. And, I have "Set Procedure to WhatEver additive" in my app startup routine.
>>
>>So, when I want to use one of the procedures from a form or class method, I usually do something like this:
>>
>>
>>Do SomeProcedure with lcSomeCharString1, lcSomeCharString, llSomeBoolValue
>>
>>
>>I like the look of my code better if I do this:
>>
>>
>>SomeProcedure(lcSomeCharString1, lcSomeCharString, llSomeBoolValue)
>>
>>
>>It seems to work either way, so, are there any pros or cons to one way over another?
>>
>>.
Previous
Reply
Map
View

Click here to load this message in the networking platform