• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 4862
  • Last Modified:

OLE Error 80030002

I am coding a Program in Borland C++ Builder 5.  I am using ADO Connections, queries, datasets, and command components.  I am initializing the COM Objects with CoInitialize(NULL), but i am always getting a return value of S_FALSE.  I realize that this means that the COM Library is already open, but I only do this call once and have a corresponding CoUninitialize for the CoInitialize.  Everything works fine until a try to connect to the SQL Server database with the ADO Component.  As soon as I do an ADOConnection1->Open(), I get an error OLE Error 80030002.  I have found out by reading other issues with this error and found that it is a file not found error.  

I decided to try to run the program on another computer and to my amazement the program works fine.  Obviously there is something wrong with my computer.  Does anybody have an idea as to what I need to look for or fix in order for my computer to run this program?
0
trs28
Asked:
trs28
  • 4
  • 2
1 Solution
 
Deepu AbrahamR & D Engineering ManagerCommented:
ADO components may not be registered/may not be available in your PC. Check whether you have MDAC (Microsoft Data Access Components) installed in your PC.If not, install MDAC from microsoft site and give it a shot.

Best Regards,
DeepuAbrahamK
0
 
Deepu AbrahamR & D Engineering ManagerCommented:
0
 
trs28Author Commented:
I tried what you requested and there was no change.  I am still having the same problem.  I even went as far as to reinstall the ado components in borland.  Any other suggestions?
0
Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

 
trs28Author Commented:
I tried the executable that I compiled on another computer and it did not work.  I found out it is only fails if I compile the executable on my machine.  I think that I may have to reinstall Borland to get rid of the error.  What do you think?
0
 
alireza815Commented:
hi
i faced the same problem.
after searching for solution, i found that the adoconnection could not find the UDL file.
so i provide the total phisical path to the UDL file and the problem resolved.
by.
My code : con.connectionstrong="File Name=tc.udl";
true code : con.connectionstring="File Name=c:\\tc.udl";
0
 
trs28Author Commented:
need to look that up ... i never even considered that ....
0
 
trs28Author Commented:
I was not able to recreate the error after leaving the project and coming back later.  I have tried the solution in a new project and did agree with this answer.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now