Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Private datasession for a class
Message
From
12/06/2002 18:23:44
 
 
To
12/06/2002 13:20:28
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00666940
Message ID:
00667695
Views:
26
Joel's technique requires that every class to support a private datasession be subclassed. My method does it without the class being modified. Joel's technique may work best for you, you control the source code.

>>Look at Message#592548 for an example of how to do what you want.
>
>Hi Albert,
>I looked at Message#592548 and found it very enlightening
>
>BUT, did you see Joel Leaches response to my question? He seems to have found an even better way of having a class use a Private DataSession.
>
>
>Define Class myCustom as Custom
>  oDS = .null.
>  Procedure Init()
>    This.oDS = CreateObject('session')
>    Set DataSession to (This.oDS.DataSessionID)
>  EndProc
>  Procedure Destroy()
>    This.oDS = .null.
>  EndProc
>EndDefine
>
>
>I tried it and it seems to work.
>Would you comment please?
>
>TIA
Previous
Reply
Map
View

Click here to load this message in the networking platform