Results 1 to 2 of 2

Thread: [RESOLVED] Object Required - VBScript

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2006
    Posts
    14

    Resolved [RESOLVED] Object Required - VBScript

    Hi all,

    I am constructing an html document with vbscript contained within it.


    Using this code, I use late binding to call a COM library reference (from a dll).

    VB Code:
    1. Dim obj1
    2. set obj1 = CreateObject("HServe.Classname")

    This appears to be created ok with no errors (If I mis-spell the "HServe.Classname" part above , I get a "ActiveX cannot create this object" message)

    However, when I attempt to use this object, for example:

    VB Code:
    1. obj1.DataMember = 1

    I get the message "Object Required: 'obj1' " in the Internet Browser error reporting.


    Does anyone have any ideas what maybe causing my problem?

    The author of the dll notes that it is an automation server dll. I have successfully used regsvr32 to register the dll.



    I should also note that the above code does not have any problems when I declare the object as
    VB Code:
    1. Dim obj1 As HServe.Classname
    in VB 6.0
    Last edited by kirovman; May 8th, 2006 at 05:30 AM.

  2. #2

    Thread Starter
    New Member
    Join Date
    Jan 2006
    Posts
    14

    Re: Object Required - VBScript

    It turns out that the author of the .dll didn't code it to allow late binding. I got around this by making my own dll which would use early binding to initialise the library.

    A bit of an inconvieniance, but it seems to work.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width