Hi Steve,
I am assuming the gsMyCursor() gets populated before the FOR myx...construct?Try the following (your code, modified) if that is the case
Dime gsMyCursor(5)
For myx = x To ALEN(gnTables)
With ThisForm.DataEnvironment
cCursor=gsMyCursor(myx)
.AddObject(cCursor, "cursor")
.&cCursor.DataBase="c:\MyFolder\Apps\Church Books\churchdata.dbc"
.&cCursor.CursorSource = gaTables(myx)
.CloseTables()
.OpenTables()
EndWith
Next myx
Let me know if this works.
------------------------------------------------
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