

- Microsoft activex data objects 2.8 library how to#
- Microsoft activex data objects 2.8 library driver#
SQL = "INSERT INTO test (TimeStamp) VALUES(?)" SQL = "INSERT INTO test (TimeStamp) VALUES(' 10:00:00')" Set DatabaseConnection = GetDatabaseConnection Private Sub Document_AfterExtract(pXDoc As CASCADELib.CscXDocument)ĭim DatabaseConnection As ADODB.Connection M_DatabaseConnection.ConnectionString = m_ConnectionString1Īdd the following code to a class script: Set m_DatabaseConnection = New ADODB.Connection Set GetDatabaseConnection = m_DatabaseConnection I changed to the 2.8 as it said 2.5 but it was a rather old posting. If Not m_DatabaseConnection Is Nothing Then Uncheck and select ActiveX Data Objects 2.8 and problem solved. Public Function GetDatabaseConnection() As ADODB.Connection ' "Provider=.4.0 Data Source=C:\Filename.mdb User Id=test Password=test"
Microsoft activex data objects 2.8 library driver#
' example for using a ODBC driver directly (MS Access) ' "Provider=MSDASQL Driver= Server=localhost UID=test PWD=test database=test" ' example for using a ODBC driver directly (MySQL) ' example for accessing a named datasourceĬonst m_ConnectionString1 As String = "DSN=TEST UID=test PWD=test" Add "Microsoft ActiveX Data Objects 2.8 Library (2.8)" ( %CommonProgramFiles%\system\ado\msado15.dll), or something similar.Īdd the following code to the project script:ĭim m_DatabaseConnection As ADODB.Connection.Choose "Edit" from the main menu and then "References.".Open the script window of the appropriate class.Full explaination or troubleshooting of ADO or ODBC are far beyond the scope of this sample.įirst you need to add a reference to MS-ADO to the script for every class the database is being used with: I have gone into References and selected 'Microsoft. I have an EXCEL VBA application (Excel 2002) that sends data to a SQLSERVER which works most of the time. As a newbie that has inherited the further customization of an application I have been experiencing an unusual problem. Like any other external COM library, the specifics of how it works and whether it works properly depend on the library itself. Solved: MISSING: Microsoft ActiveX Data Objects Record 2.8 Library. However, keep in mind that this is merely invoking the ADO COM object in WinWrap script.
Microsoft activex data objects 2.8 library how to#
Below is a sample of how to do this in KTM script. External databases can be accessed via ODBC using MS-ADO.
