I found some code in some of the postings on this site,
such as...
And I was hoping to be able to use a slight variation to
get the names of the fields in a given table...
My problem is that VBA in Access isntr ecognizing "TableDef"
as valid, it says "User-defined type not defined".
Are you using some addin that I must be missing? ADODB is
always available correct? I shouldnt have to add anything
else right? Any ideas?
Regards,
Travis Johnson
such as...
Code:
Dim tdf as TableDef
Dim fld as Field
Dim prp as Property
Set tdf=currentDB.TableDefs("OldTable")
And I was hoping to be able to use a slight variation to
get the names of the fields in a given table...
Code:
Dim tdf as TableDef
Dim fld as Field
Set tdf = currentDB.TableDefs("SomeTable")
For Each fld in tdf
'add fld.name to string array
next
My problem is that VBA in Access isntr ecognizing "TableDef"
as valid, it says "User-defined type not defined".
Are you using some addin that I must be missing? ADODB is
always available correct? I shouldnt have to add anything
else right? Any ideas?
Regards,
Travis Johnson