Install DLL with regasm witouth cmd window

733 views Asked by At

I'm trying to create a installer that uses regasm.exe to install my DLL but it open the black cmd window and i don't wan't to show it. My code looks like:

ExecWait "$MyPath\RegAsm.exe" /tlb /register /codebase /nologo /silent "$MyOtherPath\MyDLL.dll"

It doesn't write anything but it open the window. I use NSIS to create the installer

1

There are 1 answers

0
Anders On BEST ANSWER

ExecWait will display the console when you run console programs, if you don't want that then you have to use a plug-in like nsExec (part of NSIS), ExecDos or ExecCmd:

nsExec::Exec '"$MyPath\RegAsm.exe" /tlb /register /codebase /nologo /silent "$MyOtherPath\ShellContextMenu.dll"'
Pop $0 ; Process exit code or "error" in $0