Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Unregister multiple dlls.

Status
Not open for further replies.

kruxty

Programmer
Joined
Jul 17, 2001
Messages
197
Location
PT
Hi,

i know that there is a command (regsvr32) that can register/unregister any dll. The problem is that i want to register and unregister all dlls from a folder.

Anyone know if there is any application or any syntax code that can solve this problem?

Tkx to all help! ;)
 
you can do this in a batch or vbscript.

[red]"... isn't sanity really just a one trick pony anyway?! I mean, all you get is one trick, rational thinking, but when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick[/red]
 
I think that the batch file is the logic way... What is the language used by a batch file?
Can i use If, else?!

Tkx
 
in a bath file how can i do a for function that gives me all the names of the files in a way that a can user the name with regsvr32?!
 
This should get you started. It will list all the DLLs in c:\winnt\system32:
Code:
@echo off
cd C:\winnt\System32
FOR %%I IN (*.dll) DO Echo %%~fI

[red]"... isn't sanity really just a one trick pony anyway?! I mean, all you get is one trick, rational thinking, but when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick[/red]
 
This is how I setup one of my files.

@SET directory=directory where DLLs are held
@SET WTEMP=%systemroot%\temp
@SET WROOT=%SYSTEMROOT%\SYSTEM32

ECHO ---[ Pushes directory files to text file ]---
@dir %directory%\*.dll /B >%wtemp%\directoryfilesREG.txt
You can also add in right after the DLL any other files you want to unregister (OCX)

Echo ---[ Unregistering Files ]---
@for /f "tokens=*" %%A in (%wtemp%\directoryfilesREG.txt) DO @%WROOT%\REGSVR32 /U /S %directory%\%%A
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top