I
Ivar Svendsen
Hello
I have linked ACCESS 2002 to SQL SERVER 2000, and created this simple stored procedure
CREATE PROCEDURE Test AS RAISERROR('Test', 16, 1
When I doubleclick this procedure in the Access program, then Access will display 'Test' as an error message
But then I run this VBA code
CurrentProject.Connection.Execute "Test
VBA does throw an exception, and ADO does populate the Error object, but ONLY WITH THE ERROR NUMBERS
After digging around I have found out that it is because Access uses OLEDB to connect to the server. Using a separate ADO connection, using ODBC drivers, I get the errors I want
But for several reasons I do not want to make a separate connection to the server, so I am searching for a way to change the default connection string that Access uses to connect to the server
(I have tried to close CurrentProject.Connection and reopen it using ODBC, but Access does not like this.)
I have linked ACCESS 2002 to SQL SERVER 2000, and created this simple stored procedure
CREATE PROCEDURE Test AS RAISERROR('Test', 16, 1
When I doubleclick this procedure in the Access program, then Access will display 'Test' as an error message
But then I run this VBA code
CurrentProject.Connection.Execute "Test
VBA does throw an exception, and ADO does populate the Error object, but ONLY WITH THE ERROR NUMBERS
After digging around I have found out that it is because Access uses OLEDB to connect to the server. Using a separate ADO connection, using ODBC drivers, I get the errors I want
But for several reasons I do not want to make a separate connection to the server, so I am searching for a way to change the default connection string that Access uses to connect to the server
(I have tried to close CurrentProject.Connection and reopen it using ODBC, but Access does not like this.)