Overclockers Australia Forums
OCAU News - Wiki - QuickLinks - Pix - Sponsors  

Go Back   Overclockers Australia Forums > Software Topics > Programming & Software Development

Notices


Sign up for a free OCAU account and this ad will go away!
Search our forums with Google:
Reply
 
Thread Tools
Old 24th April 2012, 4:29 PM   #1
Pookey Thread Starter
Member
 
Join Date: Dec 2009
Location: Sydney
Posts: 1,578
Default Re-registering multiple DLL's with VB Script

Hey Guys,

I was wondering if someone knew of a better way to re-register a bunch of DLL's that's not messy like what's below?

Code:
Dim objShell
Set objShell = CreateObject("WScript.Shell")
objShell.Run "regsvr32.exe c:\windows\system32\whatever1.dll"
objShell.Run "regsvr32.exe c:\windows\system32\whatever2.dll"
objShell.Run "regsvr32.exe c:\windows\system32\whatever3.dll"
objShell.Run "regsvr32.exe c:\windows\system32\whatever4.dll"
Ideally, I want something like this (messy quick version):

Code:
Sub RegisterMultipleDLL(RegisterDLLArray)
Dim strDLL
If IsArray(RegisterDLLArray)
For Each strDLL in RegisterDLLArray
Some command to run regsrv32.dll /s with the appended name
Anyone able to point me in the right direction?
Pookey is offline   Reply With Quote

Join OCAU to remove this ad!
Old 27th April 2012, 12:26 PM   #2
Pookey Thread Starter
Member
 
Join Date: Dec 2009
Location: Sydney
Posts: 1,578
Default

No-one has any ideas?
Pookey is offline   Reply With Quote
Old 27th April 2012, 1:31 PM   #3
Psychotria
(Banned or Deleted)
 
Join Date: Apr 2012
Posts: 443
Default

I'm not sure. Wouldn't you just do (in the loop) objShell.Run "regsvr32.exe /s " + strDLL?

(replacing regsvr32.exe with the full path if necessary)
Psychotria is offline   Reply With Quote
Reply

Bookmarks

Sign up for a free OCAU account and this ad will go away!

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +10. The time now is 11:59 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd. -
OCAU is not responsible for the content of individual messages posted by others.
Other content copyright Overclockers Australia.
OCAU is hosted by Internode!