-
Appending Array Tables in Access with VBA
I have to append 120 tables into master table
I get runtime error. Please Help
Private Sub Append_Click()
Dim aryTables As Variant
aryTables = Array("project brd", "project udr")
For K = LBound(aryTables) To UBound(aryTables)
db.Execute "INSERT INTO master " _
& "SELECT ID, Region, Country, ProjectName, " _
& "ProjectNumber, Coordinates, BusinessDeveloper " _
& "FROM [" & aryTables(K) & "]", dbFailOnError
MsgBox db.RecordsAffected & " from table " & aryTables(K) & " were added to the master table."
Next K
End Sub
Run-Time error '424'
Object Required
Last edited by ekryez; 03-25-2014 at 04:55 PM.
Reason: tags
-
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