Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Business classes
Message
De
18/07/2001 16:32:08
Gerry Schmitz
GHS Automation Inc.
Calgary, Alberta, Canada
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00532154
Message ID:
00532201
Vues:
13
>So I bind the Controlsources of the controls on the form in the form's init event after the THISFORM.oItem.OpenAllTables().
>
>Is this the right approach to this situation, or are there better ways of doing the 2 tier design?
>
>I know that this is a long story, but this question has bothered me for some time now, so I would really appreciate some more information on this desing issue.

I do something similar. My only real question is: What are you "binding" to ?

My "DataSet classes" are private "Session" classes that have properties (ie. an interface) that the Form (via .ControlSources) is bound to. These "properties" would correspond to "fields" in the underlying "dataset". The Form communicates with the underlying "dataset" (table, query, array, "remote object", whatever) thru this interface, and the various "data access methods" (Move_First, Move_Last, Write_Record, etc.)

Not necessarily better; just the way I do it.

One advantage is I can "run/test" a Form without having a physical table/whatever in place (yet) ... or, in other words, I can "bind" without actually having something to bind to. It's relatively easy to change data sources too.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform