Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Forms and Datasessions...
Message
From
15/10/1998 16:52:03
 
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00146720
Message ID:
00147243
Views:
32
>
>Where is your code for field validations? If its in a procedure file or in code that calls the form, you'll have problems accessing the private datasession for a form. VFP insists on changing the datasession for exteranl code to a form back to the default session. Its not recommended practice, but you COULD change the datasession in your external code (SET DATASESSION TO _SCREEN.ActiveForm.DataSessionID). If the validation code is part of the object on the form, you don't have the problem of the datasession being changed.

The form(s) are being called either by a menu hit or a prev. form...the actual validation code is in one of the form's UDF methods ..which is called from the "valid" of each field to "validate" the fields contents....
The datasession is already changed/changes when the form is activated...I assume because the "READ EVENTS" was executed at the "DEFAULT" datasession level?
Sean Campbell
www.upstagesoftware.com
sc@upstagesoftware.com

**********************************************************
Eddie, I wouldn't be anymore surprised, if tomorrow I woke up with my face stapled to the living room carpet.

Clark W. Griswold
**********************************************************
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform