Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Local lnSomething as Integer
Message
From
15/06/2010 14:49:31
 
 
To
15/06/2010 14:12:20
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01469009
Message ID:
01469018
Views:
67
It's purely for Intellisense. However, I have seen times when a VFP COM object could not be consumed if the type of a parameter was not specified. So, this would not work
DEFINE CLASS Example AS Session OLEPUBLIC
    FUNCTION DoSomething(tnParam1, tcParam2)
        * Do some processing
    ENDFUNC
ENDDEFINE
But this would
DEFINE CLASS Example AS Session OLEPUBLIC
    FUNCTION DoSomething(tnParam1 AS Integer, tcParam2 AS String)
        * Do some processing
    ENDFUNC
ENDDEFINE
>I have seen references in code that look like this:
Local lnSomething as Integer
>Obviously this tells me that {lnSomething} is an integer, but I knew that because it begins with ln,
>
>So, what is the purpose in doing so? Does VFP use this information in some way?
>
>P.S.: I do understand the use of this structure when it refers to 'as Form', or whatever, just not when it refers to a datatype like String or Integer.
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer
Previous
Reply
Map
View

Click here to load this message in the networking platform