* if there is a dataenvironment... IF TYPE(".Dataenvironment.Name") = "C" LOCAL oDE oDE= THIS.Dataenvironment IF ! oDE.AutoOpenTables SetCursorPaths(m.oDE) oDE.OpenTables() ENDIF ENDIF && Dataenvironment *** Here's the essential code for SetCursorPaths() * SETCURSORPATHS() * Resets the paths in a DE to that spec'd * designed to be called from BeforeOpenTables() of DE or Load event of data form lparameter oDe local nn, oC, cName local array a_O[1] nn= amembers(a_O, m.oDe, 2) for each cName in a_O oC= evaluate("m.Ode." + m.cName) if oC.BaseClass = "Cursor" if empty(oC.Database) * If a free table adjust the cursorsource oC.CursorSource= "your file source" else * otherwise adjust the database source oC.Database= "your database source" endif endif endforIn reality I store the table locations in a table and use it to set the sources.