I have a run time error for creating duplicate values. How do I have the ADO reveiw each record and if the ID already exists, continue or skip to add the others? Here is the code:
DoCmd.TransferSpreadsheet acLink, 8, "lnkImport", varFileName, True, "Sheet1!a1:g1000"
Set Conn = New...
Hi All!
Have anyone ever import data from Excel to SQL Server using ado?
Here is the code that gives me an error: [OLE/DB Provider returned message: Unspecified error]
Dim lngRecsAff As Long
Dim strSQL As StringSet
Conn = New ADODB.Connection
Conn.Open DbConnection()
strSQL = "Select...
I did figure out, but now I cannot edit. Here is the code:
Dim rs As ADODB.Recordset
Dim strSQL As String
Set conn = New ADODB.Connection
conn.Open DbConnection
Set rs = New ADODB.Recordset
strSQL = "SELECT * FROM TreatmentProvided WHERE " & strCriteria & ""
rs.CursorLocation = adUseClient...
I am trying to bind recordset to subform using ADO and it shows only one record. Do you know what is missing here? Thank you.
Private Sub Form_Load()
Dim rs As ADODB.Recordset
Dim strSQL As String
Set conn = New ADODB.Connection
conn.Open DbConnection
Set rs = New ADODB.RecordsetstrSQL =...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.