Solved

oledbconnection.open() - External component has thrown an exception.

Posted on 2013-11-01
4
1,437 Views
Last Modified: 2013-11-23
Hello,

It is expected behaviour that a oledbconnection.open() call to access database file (mdb) that also has ldb lock file will fail ?

Last week some code I had worked fine, this week it doesn’t and the only thing I can see that’s different is the existence of a lock file in the directory.

The error is being called on oledbconnection.open() and is:

External component has thrown an exception.

Any ideas?
0
Comment
Question by:andyw27
  • 2
4 Comments
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 39617287
Delete the lock file then try again.

But ultimately you need to investigate why the locking file did not get deleted automatically.
When an Access db is opened, the locking file is created...
Likewise, when the db file is closed, the locking file should be deleted automatically...

JeffCoachman
0
 
LVL 12

Expert Comment

by:deanvanrooyen
ID: 39619970
thats weird I would suspect that even a lock would allow an open e.g. to read, what was the exception message?
0
 

Accepted Solution

by:
andyw27 earned 0 total points
ID: 39656758
Figured out the problem it was problem between the 32bit and 64bit version of office, fixed by installing the 64bit MDE with the passive switch.
0
 

Author Closing Comment

by:andyw27
ID: 39671078
Fixed myself
0

Featured Post

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now