Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
And DataSession's again...
Message
De
26/03/2003 17:17:17
Charlie Schreiner
Myers and Stauffer Consulting
Topeka, Kansas, États-Unis
 
 
À
26/03/2003 14:31:27
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00770299
Message ID:
00770491
Vues:
12
Hi Gunnar,
If you were in Form1 and called Form2's Save(), and both forms had private datasessions, wouldn't you expect that to just work? Well it does. No SET DATASESSION required.
If Form1 in your case has a default datasession, and the DBFOpen object is contained in the default datasession, then it makes sense that would work.
I'm completely with you on the SET DATASESSION TO (SET("DATASESSION")) code--I have no idea why that should do anything. You sure your form still has the datasession property set to 2?

Perhaps a better design would be to ask the Access object for the information like this:
Create a property on your form like ThisForm.UserAccess.
Then call ThisForm.UserAccess = _SCREEN.AccessObject.GetUserAccess()
The object returned has properties set with all the information your form needs.


>Hello Charlie
>
>i was under the impression that if you call any function (method in a class, or in a procedure file) from a form, the datasession is automaticly the one set from that form. in any case the funy thing is, that the 1st custom class on the _screen (called from the form) does inherit the datasession from the form, but the 2nd custom class (called from from the 1st class) does not. that's what puzzels me. if neither one of the custom classes would be in the datasession of the form, i would understand your statement, however they are not.
>
>as you might have read in this thread, i've found a solution where i 're-set' the DS in the first class just before i call the 2nd class. it sure is wired!
Charlie
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform