473,397 Members | 1,961 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

ADODB.Connection General Error only for some users?

Hello all-
Working on a tool which imports old Excel workbooks into a formatted workbook, then exports the formatted workbook to Access tables. It's working perfectly on my machine, but when my co-worker tries to run it, he gets "[Microsoft][ODBC Microsoft Access Driver]General error Unable to open registry key Temporary (volatile) Ace DSN for process" on line 6 of the following code-
Expand|Select|Wrap|Line Numbers
  1. Sub exportInformation()
  2.     Dim cn As ADODB.Connection, rs As ADODB.Recordset, iXCoord As Integer, sSheet As Worksheet, iRow As Integer, toAdd As Boolean, crs As ADODB.Recordset
  3.     Set sSheet = ThisWorkbook.Sheets(1)
  4.     Set crs = New ADODB.Recordset
  5.     Set cn = New ADODB.Connection
  6.     cn.Open "Driver={Microsoft Access Driver (*.mdb, *.accdb)}; Dbq=Z:\_Database\TestDatabase.accdb; Uid = Admin; Pwd = ;" '<-- Causes error
  7.     Set rs = New ADODB.Recordset
  8.     rs.Open "BOM", cn, adOpenKeyset, adLockOptimistic
Z:\_Database is a folder that he is connected to (and has permissions for), and when he runs it through another path it works fine. We are both running this code from Excel 2013, we've checked our References to make sure they match... Most of the solutions I've seen have said to either try restarting the computer to get rid of any residual exclusive instances of the database or to check the permissions, but neither solution has helped. Any thoughts on the matter would be greatly appreciated.
Thank you in advance!
-RW
Jul 14 '15 #1
2 1464
Seth Schrock
2,965 Expert 2GB
I'm not at all familiar with ADODB, but the error message mentions a DSN. You might make sure that your co-worker has the same DSNs as you do.
Jul 14 '15 #2
Yup. (Or, well, I guess I'm a little unclear on what a DSN is... After some fairly extensive searching, I'm pretty sure I've got this right.) Same file path, file name... I'm PRETTY sure this should be a DSN-less connection string anyway. It's an ODBC Driver. (I got the Connection String structure from https://www.connectionstrings.com/mi...dard-security/ <-- there)
Jul 14 '15 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Bina Desai | last post by:
I get the following error: Error Type: Microsoft VBScript runtime (0x800A01A8) Object required: '' /myweb4/authorised_user_page.asp, line 70 and line 70 of my code is: <% rsCheckUser1.Open...
1
by: June Moore | last post by:
Hi, I am getting an error with the following code. Error is: ADODB.Connection error '800a0e78' - The operation requested by the application is not allowed if the object is closed. Any ideas how...
1
by: Nigel C | last post by:
Access 2000 - A am trying to access another Access 2000 database from a code module. I have seen examples of the ADODB connection string - to connect to an access database however the database...
0
by: Andre Azevedo | last post by:
Hi all ! I've created a .net serviced component with only one method. This method receive an ADODB.Command object and execute it. The ADODB.Command object is created in the client process. (VB...
2
by: Jim Lacenski | last post by:
I have a VB class that uses .NET and ADODB to write into an Excel spreadsheet (via Jet) on a server as part of a web application. ADODB is used instead of ADO.NET because it greatly simplifies the...
7
by: STUPIDFORUM | last post by:
ADODB.Recordset "The connection cannot be used to perform this operation." "Microsoft Access Driver" ERROR 0X800A0E7D OLE exception from "ADODB.Recordset": The connection cannot be used to...
1
by: =?Utf-8?B?VmVua2F0ZXNhbiBT?= | last post by:
Hi, I have a requirement of consuming a connection object returned from a COM component deployed in COM+ application. I have given the need for this requirement end of my query. My component...
1
by: rnashting | last post by:
Hello again everyone! I'm having an error trying to retrieve things into a form from a database. I'm just learning, so I'm using the Northwind template that access has, but I'm getting an error...
5
by: ricovox | last post by:
Hello, Every time I try to create an ADODB.Connection object, I receive the following error: ----------- Runtime Error '-2147024703 (800700c1)': Automation error %1 is not a valid Win32...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.