Solved

ActiveX component can't create object

Posted on 2002-06-03
7
693 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
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 
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

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

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

Suggested Solutions

I would like to start this tip/trick by saying Thank You, to all who said that this could not be done, as it forced me to make sure that it could be accomplished. :) To start, I want to make sure everyone understands the importance of utilizing p…
Have you ever needed to get an ASP script to wait for a while? I have, just to let something else happen. Or in my case, to allow other stuff to happen while I was murdering my MySQL database with an update. The Original Issue This was written…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

770 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