Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
DataEnvironment acting funny
Message
De
17/02/1999 02:30:24
 
 
À
16/02/1999 14:36:01
Noman Aftab
Embry-Riddle Aeronautical University
Daytona Beach, Floride, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00187698
Message ID:
00188294
Vues:
17
Try that, Noman, as a panacea and report back!


>* Stores current database
>cDbcpathname=dbc()
>
>* Closes all tables in dataenvironment
>Thisform.DataEnvironment.CloseTables
>
>* creates an array with names of the member properties
>=AMEMBERS(laProplist, ThisForm.DataEnvironment, 2)
>
>* Stores length of the array
>nArraylen = ALEN(laProplist, 1)
>
>* returns to calling program if DE is empty
>IF EMPTY(laProplist[1])
> RETURN
>ENDIF
>
>* loops to look through the contents of an array
>IF nArrayLen > 0
> FOR IDcount = 1 TO nArraylen
> cObjname = EVAL('THISFORM.Dataenvironment.' + laProplist[IDcount])
> * changes cursor's reference database path to current database path
> IF LOWER(cObjname.Baseclass) = 'cursor'
> IF !EMPTY(cObjname.Database)
> cObjname.Database = cDbcpathname
> ENDIF
> ENDIF
> NEXT
>ENDIF
>
>* Opens all tables in dataenvironment
>Thisform.DataEnvironment.OpenTables
>
>* Refreshes information on each page
>THISFORM.DataInput.Refresh()
>
>
>This method is called DataEnvTables. I am calling it during form initializion. Should I put this code in DE mehod 'beforeopentables' to get rid of any errors.
>Thanks.
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform