Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problems with Dataenvironment
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00691805
Message ID:
00692058
Vues:
24
I was hoping to see code like the following:


 
LOCAL oDE
oDE = CREATEOBJECT('custom_de')
set
WAIT WINDOW "DataEnviroment has been created"
BROWSE

DEFINE CLASS custom_de as dataenvironment
AutoOpenTables = .T.
AutoCloseTables = .T.
ADD OBJECT oCustomer as csrCustomer

PROCEDURE Init
IF This.AutoOpenTables
WAIT WINDOW "OpenTables() is about to be called"
This.OpenTables()
ENDIF
ENDPROC

PROCEDURE Destroy
IF this.AutoCloseTables
WAIT WINDOW "CloseTables() is about to be called"
This.CloseTables()
ENDIF
ENDPROC

PROCEDURE OpenTables
WAIT WINDOW "Currently executing the OpenTables() method"
ENDPROC

PROCEDURE CloseTables
WAIT WINDOW "Currently executing the CloseTables() method"
ENDPROC
ENDDEFINE

DEFINE CLASS csrCustomer as Cursor
Alias = "Customer"
CursorSource = "Customer"
Database = HOME(2) + "Data\TestData.dbc"
ENDDEFINE


In either case, is this similar to what you have? I don't understand why you have NODEFAULT then immediately followed by DODEFAULT() clauses in your code. Can you show more of your code. Maybe that'll help understand why your code doesn't work. By the way, the code above work just fine in my environment.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform