We have installshield 2016 and inside this we are running installer script. That script is call through custom action.
So we are written following commnad to register "mydll.dll" as below mentioned command, C:\Windows\Microsoft.NET\Framework\v4.0.30319\regasm.exe /codebase mydll.dll The above command works perfectly fine when run manually through command prompt with administrative access.But fails through installer created using installshield script custom action.
To run command we use LaunchApplicationAndWait() and LaunchApplication() functions as strcmd = "path to cmd.exe" + "cmd.exe" strcmdopt = "path to regasm.exe" + "regasm.exe " + /codebase + path and name of dll
ret = LaunchApplication(strcmd, strcmdopt, windir, sw_normal, infinite, LAAW_OPTION_WAIT | LAAW_OPTION_SHELLEXECUTE)
similarly ret = LaunchApplicationAndWait(strcmd ,strcmdopt,LAAW_OPTION_WAIT | LAAW_OPTION_HIDDEN)
My Question is why both command not work when run through installshield custom action scripts
Is the dll distributed with the installation? if so, is the file present in the installdir (or wherever) when the script is called? Maybe add some msg box for debug purposes to see if this condition is met.
Im using deferred custom action to register .dll via regasm and it works just fine.