Solved

ActiveX component can't create object

Posted on 2002-06-03
7
689 Views
Last Modified: 2012-06-27
The following code cause an "ActiveX component can't create object" on the "set en=rdoenvironments(0)" line.
I am running this on a W 2000 Advanced server.

Dim Cn As New rdoConnection
    Dim En As rdoEnvironment
    Dim Qd As New rdoQuery
    Dim Rs As rdoResultset
    Dim Conn As String
    Dim tempcnt As Integer
    Dim strDate, strQd$, strQd1$
       
       Command1.Caption = "Start"
       Conn = "UID=scott;PWD=tiger;dsn=o9ia;SERVER=o9ia;"
       
       Set En = rdoEnvironments(0)
       En.CursorDriver = rdUseOdbc
       With Cn
           .Connect = Conn
           .CursorDriver = rdUseOdbc
           .EstablishConnection rdDriverNoPrompt, False
       End With

       Set Qd.ActiveConnection = Cn

       Qd.SQL = "{call gjb_testdate1(?,?)}"
       Qd(0).Direction = rdParamInput
       Qd(1).Direction = rdParamOutput
       Qd(0).Type = rdTypeDATE
       
       Qd(0) = CDate("1/1/1900")
       Qd.Execute
       strQd = Mid(Qd(1), 12)
       strQd1 = Mid(Qd(1), 1, 11)
       Debug.Print "For the date you entered: " & strQd1 & vbCrLf & strQd
       MsgBox "For the date you entered: " & strQd1 & vbCrLf & strQd

   End Sub

   
I tried register and rdo.rd.... and still get "429". The procedure is try to call an oracle procedure.
 

0
Comment
Question by:MrCrawfish
7 Comments
 
LVL 2

Expert Comment

by:chops123
ID: 7053122
This error is encountered when the Active-X component you have referenced is not registered on your machine.

If you are using a self made Active-X Component,you need to register the same on you PC.

Do the foll:

Click on Start-Run and type the following.

regsvr32 c:\foldername\myComponent.dll

This will register the DLL in your PC.

Rgds
KC
0
 

Expert Comment

by:basha_ahmad
ID: 7053374
Mr. CrawFish...

    Check out whether rdo library has been registered on
your pc. if it is not then get it registered.

    The DLL is MSRDO20.dll which you can get without a prob.

The registration process is same as chops has said.

bye
basha
0
 
LVL 1

Accepted Solution

by:
toys032498 earned 50 total points
ID: 7053887

Use Option Explicit

You have

Dim En As rdoEnvironment

Set En = rdoEnvironments(0) ' You spelled it wrong -> added a "s"
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 5

Expert Comment

by:rpai
ID: 7054625
0
 

Expert Comment

by:raja_velpuru
ID: 7054652
Are u writing VB or ASP?

If it is VB,
u have to use:

Dim en As RDO.rdoEnvironment
Set en = rdoEngine.rdoEnvironments(0)
0
 
LVL 2

Expert Comment

by:chops123
ID: 7055633
From the code,MrCrawfish seems to be using VB.

The only issue is DLL registration.Once registered,you will be through with your program

Rgds
KC
0
 
LVL 4

Expert Comment

by:Wakie
ID: 9142926
It appears this question has been abandoned.

I will leave a recommendation in the Cleanup topic area that this question will be:

- Question PAQ'd and points to toys -

Please leave any comments here within the next seven days.

DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

Wakie,
EE Cleanup Volunteer.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
I have helped a lot of people on EE with their coding sources and have enjoyed near about every minute of it. Sometimes it can get a little tedious but it is always a challenge and the one thing that I always say is:  The Exchange of information …
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

920 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

15 Experts available now in Live!

Get 1:1 Help Now