Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Private datasessions for functions and procedures
Message
From
17/11/1999 12:10:54
 
 
To
16/11/1999 23:07:25
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00291735
Message ID:
00291965
Views:
22
Hi Mike,
Great idea. If using VFP6, why not define the class as SESSION rather than FORM.

>Hi Evan,
>
>>I would like my functions and procedures to have private datasessions. Three reasons:
>>Can anyone point to towards some resources on how to do this? Any the cons to this idea?
>
>If I'm not mistaken, thats what the Session object is for, just create an instance of one set to private, and set the datasession to that, walla, a new DS. Or even simpler, create an instance of a form class:
>
>
local lnDS
>
>lnDS = set('datasession')
>oSession = createobject('MySession')
>set datasession to (oSession.DataSessionID)
>
>*Code Stuff
>
>set datasession to (lnDS)
>release oSession
>
>DEFINE CLASS MySession AS FORM
>
>    Name = Session1
>    DataSession = 2
>
>ENDDEFINE
>
>That should be the way to do, giving a PRG a datasession at design time just seems silly, IMO.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform