active x dll help user defined function not identified

Posted on 2004-11-12
Last Modified: 2013-11-25
I am trying to create an activex dll out of my project. So that I can then call it from an asp web page Here is an example of one of the functions.  When I try to compile it i get the error user defined type not defined
on the dim rs as adodb.recordset and on the dim cmd
actually on all the adodb stuff it bombs out.
Now when I use thios as a regular exe it is fine. I just coppied the coed over into an active x module. I thought that it be just fine. what do I not understand about it?
Can adodb be in the active x dll or not.
Or should the active x dll call the other project?

Public Function ship(ByVal numb As Integer, ByVal shipN As String, ByVal shipc As String, ByVal add1 As String, _
                     ByVal add2 As String, ByVal city As String, ByVal state As String, ByVal zip As String, ByVal country As String, _
                     ByVal amount As Integer, ByVal stroption As String)
Dim intNumbShip As Integer
Dim intupdateNumb As Integer
intupdateNumb = 0

   strShipName1 = shipN
   strCompName1 = shipc
   strAdd11 = add1
   strAdd12 = add2
   City1 = city
   strState1 = state
   intZip1 = zip
   strCountry1 = country
   strShipOption1 = stroption
   intshipAmount1 = amount


Dim rs As ADODB.Recordset
Dim cn As ADODB.Connection
Dim cmd As ADODB.Command
Dim rs As ADODB.Recordset
Set rs = New ADODB.Recordset
rs.Open "shipping", CONNECTIONSTRING, adOpenKeyset, adLockOptimistic, adCmdTable

   rs.AddNew Array("shipPerson", "ship_comp", "ship_Add1", "Ship_Add2", "ship_City", "ship_State", "ship_zip", "ship_Coountry", "ship_Amount", "ship_Option", "customer_ID"), _
                  Array(strShipName1, strCompName1, strAdd11, strAdd12, City1, strState1, intZip1, strCountry1, intshipAmount1, intshipAmount1, intOrderID)
   Set rs = Nothing

thanks for any help
Question by:shayne23d
    1 Comment
    LVL 32

    Accepted Solution

    From the Project->References menu make sure that your database reference is included ("Microsoft Activex Data Objects...").

    Featured Post

    Gigs: Get Your Project Delivered by an Expert

    Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

    Join & Write a Comment

    Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
    Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
    Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
    Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

    745 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

    16 Experts available now in Live!

    Get 1:1 Help Now