|
-
Nov 6th, 2002, 09:25 PM
#1
Thread Starter
Addicted Member
create new table in a loop (ADO)?
hi all,
The following is a for loop that will read the feature name, I would like to add them as the field names of a new table of a mdb. How could I do this?
Dim dbs As Database
For n = 0 To FieldCount - 1
aSTR = FieldName(n)
dbs.Execute "CREATE TABLE new(????);"
Next n
in the same case, I would like to fill the table with the values of each field in a loop,
For j=1 to recordcount
For n = 1 To FieldCount - 1
aSTR = CStr(RecordValue(j, fieldName(n))
Next n
Next j
'RecordValue(j, fieldName(n)) is the value of the j record at n'th field
Thanks very much!!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|