Results 1 to 3 of 3

Thread: dll's and ocx at run time

  1. #1

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

    Question

    I would like to know how to register dll's at run time on another computer. Cuz i doing sort of a setup program to install my application and i need to know what to do when i copy my activex(.ocx) and my dll's.Where to copy it and how?
    Do i register them and then window will put it where it belong or i put it where i think it belong and then register them.I need to know, thank you!!!

  2. #2
    Fanatic Member simonm's Avatar
    Join Date
    Sep 2000
    Location
    Devon, England
    Posts
    796

    Cool Both...

    You have to both put the files there (with their associated .lib and .exp files) and register them.

    The only way I know how to manually register dll's is to use the 'RegSvr32.exe' which can be run in the Windows\System directory.

    You could use vb 'Shell' command to run this program.

    Looks something like this:

    Regsvr32 MyFile.dll



    Simon.

  3. #3
    Guest

    Smile dunno if this'll help, but..

    this function will register your .ocx control:

    Code:
    Private Declare Function RegComCtl32 Lib myActiveX.OCX" _
        Alias "DllRegisterServer" () As Long
    and this example shows you how and where it can be called:

    Code:
    Private Sub UserControl_Initialize()
    
      If RegComCtl32 = ERROR_SUCCESS Then
        BindDone = False
      Else
        MsgBox "Registration Unsuccessful"
      End If
      
    End Sub
    dunno if it's any help, but i tried.

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