The cursor is created in the session where the object that creates the cursor was instantiated. I would suggest to change the method that creates the cursor to receive the datasessionid as parameter:
Procedure CreateCursor Lparameters tnDataSessionId Private SessionHasBeenChanged If Vartype(tnDataSessionId) = "N" && it was passed Set DataSession To tnDataSessionId SessionHasBeenChanged = .T. EndIf *-- Create the cursor here If SessionHasBeenChanged Set DataSession To 1 EndIf The procedure is called from that form with CreateCursor(ThisForm.DataSessionId) -----Original Message----- From: profoxtech-boun...@leafe.com [mailto:profoxtech-boun...@leafe.com] On Behalf Of Kent Belan Sent: Saturday, June 25, 2011 10:56 PM To: profoxt...@leafe.com Subject: Private Data Session Hello, I have a VPF9 form that is set to Private Data Session. I need to call a method in a global class that creates a cursor. When I get back from the method call, the cursor does not exist. What is the trick to pass this cursor back to the private form ? Thanks, Kent [excessive quoting removed by server] _______________________________________________ Post Messages to: ProFox@leafe.com Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/000301cc3374$295745b0$7c05d110$@gmail.com ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.