Jump to content

Registering a .dll using RunOnceEx


Recommended Posts

I have a .dll which i am trying to register, it works using GuiRunOnce:

[GuiRunOnce]

Command0="regsvr32 /s %SYSTEMDRIVE%\file.dll"

But i want to use RunOnceEx to install this and other stuff so can the above be done RunOnceEx?

I have tried various ways of putting the above command in RunOnceEx but it will not register.

If it cant be done are there other methods to register the .dll?

Thanks.

Link to comment
Share on other sites


Use this code and it works:

REG ADD %KEY%\001 /V 1 /D "regsvr32 /s file.dll" /f

I must say, that my .dll file is in the system32 folder, but you can try to register it from your location of the .dll.

Edited by HØLLØW
Link to comment
Share on other sites

Hi, HØLLØW, i was trying something similar, but i had it the wrong way round, the file/location before the command.

As for the location it says to place it in %systemdrive%, i have tried it directly in system 32 and it didnt register (this was from GuiRunOnce - which i know works, from putting the file in %systemdrive%) but it might using what you suggested.

If i have it to copy over to system32, and use the command you gave, does it automatically look in the system32 folder, as the command you gave doesn't specify the file location?

I'll give it a go, thanks.

Edited by andys_50
Link to comment
Share on other sites

[...]i have tried it directly in system 32 and it didnt register[...]

Then you used the wrong command syntax; it dosen't matter where the file is placed for registering it...

If i have it to copy over to system32, and use the command you gave, does it automatically look in the system32 folder, as the command you gave doesn't specify the file location?

If the file to register/unregister is in a location defined in your %path% environment variable(google it, if you don't know what that means), then you don't need to add a path to the regsvr32 command(or any others for that matter). By default, then '%windir%\system' and '%windir%\system32' is defined in the %path% environment variable...

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...