Ed,
I haven't tried the code you posted, but your explanation makes sense to me. Would you then still use the DE in the forms? What about hard-coded paths that seem to be stored in the DE?
Bonnie
>Bonnie, the reason that opening the tables in the main improves the performance of the forms is that VFP can reduce or eliminate the most costly (in terms of time) part of the USE statement; searching the directory for the appropriate file entries and performing the low-level file open that creates the reference used by VFP to 'talk' to the file. Once a file is open, a handle (a reference) for the file exists, and VFP can duplicate that reference rather than go through the whole process of redoing the low-level open again. You can demonstrate this to yourself by comparing the times for the two code snippets below: