Results 1 to 11 of 11

Thread: How to Register

  1. #1

    Thread Starter
    Fanatic Member vbPoet's Avatar
    Join Date
    Feb 2005
    Location
    Searching ..
    Posts
    669

    How to Register

    I m facing a problem.
    i have forgotten what is the way to register dll in Application Directory on
    Form Load Event ....

    Thx in Advance

  2. #2
    Banned dglienna's Avatar
    Join Date
    Jun 2004
    Location
    Center of it all
    Posts
    17,901

    Re: How to Register

    Use the windows directory, for xp, it is like this:

    VB Code:
    1. shell "c:\windows\system32\regsvr32 myapp.dll"

  3. #3

    Thread Starter
    Fanatic Member vbPoet's Avatar
    Join Date
    Feb 2005
    Location
    Searching ..
    Posts
    669

    Re: How to Register

    Quote Originally Posted by dglienna
    Use the windows directory, for xp, it is like this:

    VB Code:
    1. shell "c:\windows\system32\regsvr32 myapp.dll"

    Sorry DG it is not working ..

    Is there any way that i can put my DLL in resource file so that it will also become safe from renaming or such type of other issues ...?

  4. #4
    Junior Member
    Join Date
    May 2005
    Posts
    19

    Re: How to Register


  5. #5

    Thread Starter
    Fanatic Member vbPoet's Avatar
    Join Date
    Feb 2005
    Location
    Searching ..
    Posts
    669

    Re: How to Register

    What i exactly want is that
    When i will give source code + DLL to others

    Then they should not place this dll in System32 and then Project | Reference | Blah Blah...

    I want to facilitate them without any headache and my program should automatically look in Application folder for given name of DLL and then register it .. without telling user about that....

  6. #6
    Banned dglienna's Avatar
    Join Date
    Jun 2004
    Location
    Center of it all
    Posts
    17,901

    Re: How to Register

    I hope you put the .exe on the regsvr32 I forgot it, as it runs from the run command.

    You could try this. I did, and it registered my dll.

    VB Code:
    1. Option Explicit
    2.  
    3. Private Sub Form_Load()
    4.  Shell "C:\Windows\System32\regsvr32.exe C:\Windows\System32\myapp.dll "
    5. End Sub

  7. #7

    Thread Starter
    Fanatic Member vbPoet's Avatar
    Join Date
    Feb 2005
    Location
    Searching ..
    Posts
    669

    Re: How to Register

    Quote Originally Posted by dglienna
    I hope you put the .exe on the regsvr32 I forgot it, as it runs from the run command.

    You could try this. I did, and it registered my dll.

    VB Code:
    1. Option Explicit
    2.  
    3. Private Sub Form_Load()
    4.  Shell "C:\Windows\System32\regsvr32.exe C:\Windows\System32\myapp.dll "
    5. End Sub





    But there is one problem ...
    It displays Msg Box about Registration of DLL ...
    it will disturbs my user....

  8. #8
    Lively Member
    Join Date
    Feb 2005
    Posts
    107

    Re: How to Register

    Add /s after "C:\Windows\System32\regsvr32.exe", should work..

    So like

    VB Code:
    1. Shell "C:\Windows\System32\regsvr32.exe /s C:\Windows\System32\myapp.dll"
    Last edited by BefunMunkToloGen; May 7th, 2005 at 08:38 PM.

  9. #9
    Banned dglienna's Avatar
    Join Date
    Jun 2004
    Location
    Center of it all
    Posts
    17,901

    Re: How to Register

    I think you have a typo, except that you did the same thing twice
    VB Code:
    1. Shell "C:\Windows\System32\regsvr32.exe /s C:\Windows\System32\myapp.dll"

    Where the /s is SILENT

  10. #10
    Lively Member
    Join Date
    Feb 2005
    Posts
    107

    Re: How to Register

    Yeah thanks for correcting that

  11. #11
    Banned randem's Avatar
    Join Date
    Oct 2002
    Location
    Maui, Hawaii
    Posts
    11,385

    Re: How to Register

    vbPoet,

    That is not a good idea, unless the dll/ocx/exe you are registering are of your own making. The reason being that if you re-register a file that is already on the system you will replace it with yours, and you know what happens if you load an dll that the user has been using and then their apps stop working and yours is the only one that does 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