Solved

Run Time Error 429: ActiveX component can't create object

Posted on 2001-08-06
23
346 Views
Last Modified: 2007-12-19
Hello,
     I'm receiving a "Run-time error 429: ActiveX
component can't create object" whenever I try to run
a ACCESS DB program. I've went to the MICROSOFT knowledge
base support site for an answer. Found one but when i
ran the Set dbs = DBEngine .OpenDatabase("<path>\<filename>"), I continue to get the same error.
Seems that in the Debug statement Set dbs functionality
is not saving the option that I set for it. Has anyone
experinced this problem before. If so what was the best
way to fix it. This question is worth 300 points, becuase
it's kicking my butt.

0
Comment
Question by:CTM
  • 10
  • 6
  • 4
  • +2
23 Comments
 
LVL 5

Expert Comment

by:KMAN
Comment Utility
You don't show all your code, but without opening a second instance of Jet, this is all you need:

Set dbs = OpenDatabase("<path>\<filename>")

Also, this collection is aonly available if you are using DAO. ADODB has no Database or Workspace collections, just Connections.

Is your DBEngine object valid when the Set dbs... happens?
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
Does one of your forms have a calender control or any ACTx control of that sort? If so see if you have a missing reference and if not then do not use the control on a continuos form
0
 
LVL 14

Expert Comment

by:mgrattan
Comment Utility
Is the database in Access 97 or 2000?  If it was converted recently from A97 to A2K you might need to adjust the project references.  Open any code module and select Tools/References from the menu.  Check the list and make sure that Microsoft DAO 3.6 is selected and shows up higher in priority than the reference for Microsoft ActiveX Data Objects (ADO).  
0
 
LVL 6

Accepted Solution

by:
devtha earned 300 total points
Comment Utility
>?????????
0
 

Author Comment

by:CTM
Comment Utility
KMAN, MGRATTAN,DEVTHA,
                     To clearify the question. The MS Access in use is 97. I have a DEBUG statement that specifices that Set dbs is not configured (it's highlighted
in yellow). I can send each of you a copy of this via
email so that you may get more info that I'm not able to
provide. My email is psd31@navsta.rota.navy.mil. Email
me and I'll provide the Debug statement to you.

CTM
0
 
LVL 5

Expert Comment

by:KMAN
Comment Utility
Looking at your code, I see you are not destroying collections when you are finished with them. Destroying means:
 Set dbs = Nothing
...for example.

In your code for Sub FillOptions, you set dbs to open an external Database, create some recordsets, the close, but you never destroy it.  Then your button code attempts to be set to CurrentDb.  This may not cause your error, but it is necessary to practice the collection destruction to prevent Access from hanging and inevitable corrupting.

Also, you could simply refer to CurrentDb when setting a recordset for this instance.  Like:
Set rst = CurrentDb.OpenRecordset("strSQL", dbOpenDynaset)

Hope this helps, K
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
How does it work CT?
0
 
LVL 14

Expert Comment

by:mgrattan
Comment Utility
devtha,

did you already fix this for CTM?
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
Yes CT sent me the mdb and I sent it back to CT?
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
Obviously after fixing the problem
0
 
LVL 14

Expert Comment

by:mgrattan
Comment Utility
So, what was the solution?
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 
LVL 5

Expert Comment

by:KMAN
Comment Utility
This has to rank up there with the worst threads in the Access Topic area.

Isn't the purpose of EE to solve problems but also to share solutions to the problems?  Why is this question different?
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
Let us wait CT's response and I shall put the solution.
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
KMAN:
Come on now, this solution is not accepted by CT. The db seems to be working fine so please be patient It was CT's who asked to send him an email for a copy of the mdb. I did respond and it worked out. So let us wait for his response.
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
CT your response?
0
 
LVL 6

Expert Comment

by:PsychoDazey
Comment Utility
CT-
I had this same issue and it turned out to be my .dll files.  Have you changed any .dll's or installed any new Microsoft programs?  If so, you will have to register your .dll using regsvr32.exe
0
 

Author Comment

by:CTM
Comment Utility
Devtha,
      Thanks a lot. You did a excellent job on the Database. I really appreciate your help. I'm referring
you to one of the guys who wrote that database. He's
still in a learning curve on working with access. I'll
be sending him your email addresses. Again thanks.

CTM
0
 
LVL 14

Expert Comment

by:mgrattan
Comment Utility
And the solution was.....?????
0
 
LVL 5

Expert Comment

by:KMAN
Comment Utility
So devtha fixed the database, but my question is, did CTM learn anything?  I sure didn't.
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
OK the database was in a uncompiled state and upon decompile and compile I got errors that I had to look into. There was a sub on one of the forms that was refering to chk boxes that never existed. I removed the sub also the form was crashing on the following lines.

'Set dbs = OpenDatabase("<path>\<filemane>")
    'TAKE A LOOK AT THIE FOLLOWING LINE CLARENCE
   
    Set dbs = CurrentDb()

I hope this calms you guys down and concentrate on some other questions.
0
 
LVL 14

Expert Comment

by:mgrattan
Comment Utility
devtha,

I think you know better than that.  You need to explain what was causing the form to "crash" on that particular line of code and what you did to resolve it.  That was the original question and, as yet, nobody has posted the solution to that question.

In your last comment, you posted the lines of code that were crashing but you did not indicate what the solution was.  Did changing the line from OpenDatabase() to CurrentDb() fix the problem?  If not, what did?  If that did fix the problem, why?

Don't get upset if we are asking for this information; it is expected by the users and other experts as well as by the moderators and I'm sure you are aware of this.
0
 
LVL 6

Expert Comment

by:devtha
Comment Utility
Thats is not a problem MG...I just cannot stand the sarcasm.

'Set dbs = OpenDatabase("<path>\<filemane>")
   'TAKE A LOOK AT THIE FOLLOWING LINE CLARENCE
   
   Set dbs = CurrentDb()

As you can see the commented line was causing problem.
and my comments for Clarence states that the following line was used instead.
That is why I did not delete the old line so Clarence can figure out the difference.
Rest I explained earlier.
Cheers.
:-)
0
 
LVL 14

Expert Comment

by:mgrattan
Comment Utility
Thank you.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

When you are entering numbers in a speadsheet, and don't remember what 6×7 is, you just type “=6*7" instead. It works in every cell! This is not so in Access. To enter the elusive 42 in a text box, you have to find a calculator, and then copy the re…
I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

728 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

10 Experts available now in Live!

Get 1:1 Help Now