Video Screencast Help

Installer won't register .WSC file

Created: 15 Jul 2010 • Updated: 15 Jul 2010 | 1 comment

My project needs a Windows Scripting Component (.wsc) to be registered. No problem getting .dll's to register, but stuck on this.  End users can manually register the .wsc file after installing the package (using regsvr32 or R-click file and select "register"), but we need the installer to register. Using Wise for Windows Installer 5.0 Pro  (its for an old VB6 package).

Can't figure out how to get the .WSC file to register. Any help much appreciated...

Tried: File Details | Self-registration |
Registration Method=Unordered (normal Windows behavior) and
Registration Method=Use order specified below
Tried custom action: "Execute Program From Destination" specifying INSTALLDIR as the working directory and for EXE and Command Line I have: regsvr32.exe myfile.wsc

Alternative will be to create a .dll, but trying to keep it simple.

Many thanks in advance if you can give some advice... EpiD

Comments 1 CommentJump to latest comment

EdT's picture

Since you can register the WSC using regsvr32.exe manually, that is your solution, but the way you have tried it may not be 100% reliable.

Try again using Execute Program from Destination.  For the executable, specify: [SystemFolder]regsvr32.exe  (always include a full path)
For the argument, specify: /s [INSTALLDIR]myfile.wsc

The other important factor is to make sure you sequence the action correctly. I would recommend placing it just after InstallFinalize.
That will ensure that your WSC file is definitely installed.

If this does not work, you will need to capture the process of manual registration and add these registry keys to your installation.

If your issue has been solved, please use the "Mark as Solution" link on the most relevant thread.