K Kevin Oct 1, 2004 #1 How can I test for amissing object? i.e. table, form, etc? Thanks in advance--again!
A Allen Browne Oct 2, 2004 #2 Assuming you know the name of the object you want to find, and what type it is (form, table, ...), you could query the MSysObjects table. Example: Is there a local table named "MyTable" Not IsNull(DLookup("Name", "MSysObjects", "([Name] = ""MyTable"") AND ([Type] = 1)")) Type Ojbect =-=- =-=-=- 1 Table 4 ODBC linked table 5 Query 6 linked table -32768 Form -32764 Report -32761 Module
Assuming you know the name of the object you want to find, and what type it is (form, table, ...), you could query the MSysObjects table. Example: Is there a local table named "MyTable" Not IsNull(DLookup("Name", "MSysObjects", "([Name] = ""MyTable"") AND ([Type] = 1)")) Type Ojbect =-=- =-=-=- 1 Table 4 ODBC linked table 5 Query 6 linked table -32768 Form -32764 Report -32761 Module