I have a VBA project that connects to a Oracle DB and runs some SQL queries. Now, the code is working smooth in Windows 7 machines, but not in Windows 10. My connection string is as below:
Dim conn As ADODB.Connection
Dim rs As ADODB.Recordset
Dim sConnString As String
sConnString = "Driver={Microsoft ODBC for Oracle}; " & _
"CONNECTSTRING=(DESCRIPTION=" & _
"(ADDRESS=(PROTOCOL=TCP)" & _
"(HOST=" & "localhost" & ")(PORT=" & "19005" & "))" & _
"(CONNECT_DATA=(SERVICE_NAME=" & "XXXXXXXX" & "))); uid=" & username & " ;pwd=" & pwd & ";"
Set conn = New ADODB.Connection
Set rs = New ADODB.Recordset
conn.Open sConnString
I have attached the screenshot of the error message that I received while running it in Winidows 10 using Excel 2016.
The code was written in Excel 2013 in the Windows 7 machine. Any solution for this?