C
CR3
I have a database with the following code from a macro:
DoCmd.TransferSpreadsheet acImport, 8, "Schneidernew", Me.File, False,
"A2:K300"
MsgBox "Data Importing Complete.", , ""
With cmd1
..ActiveConnection = CurrentProject.Connection
..CommandText = "Schneider_Append_DDR;"
..Execute
End With
With cmd1
..ActiveConnection = CurrentProject.Connection
..CommandText = "Update_Carrier_Schneider;"
..Execute
End With
DoCmd.DeleteObject acTable, "Schneidernew"
Import_Schneider_Exit:
Exit Sub
Import_Schneider_Err:
MsgBox Error$
Resume Import_Schneider_Exit
End If
exit_err_error:
End Sub
In the above code, I continue to get an error with this part of the statement:
With cmd1
..ActiveConnection = CurrentProject.Connection
..CommandText = "Schneider_Append_DDR;"
..Execute
End With
The ".Execute" will not work. Does anyone know why this might be happening?
Thank you.
DoCmd.TransferSpreadsheet acImport, 8, "Schneidernew", Me.File, False,
"A2:K300"
MsgBox "Data Importing Complete.", , ""
With cmd1
..ActiveConnection = CurrentProject.Connection
..CommandText = "Schneider_Append_DDR;"
..Execute
End With
With cmd1
..ActiveConnection = CurrentProject.Connection
..CommandText = "Update_Carrier_Schneider;"
..Execute
End With
DoCmd.DeleteObject acTable, "Schneidernew"
Import_Schneider_Exit:
Exit Sub
Import_Schneider_Err:
MsgBox Error$
Resume Import_Schneider_Exit
End If
exit_err_error:
End Sub
In the above code, I continue to get an error with this part of the statement:
With cmd1
..ActiveConnection = CurrentProject.Connection
..CommandText = "Schneider_Append_DDR;"
..Execute
End With
The ".Execute" will not work. Does anyone know why this might be happening?
Thank you.