Archive: registering AcitveX-Exe ?


registering AcitveX-Exe ?
Hi there,
does anybody know a way for successfully registering an VB-ActiveX-Exe ?

If one would do it manually one would just start the file with the parameter /regserver -> 'c:\myActiveX.exe /regserver'.
I tried different ways:
- ExecShell "$INSTDIR\${PRODUCTNAME}.exe \regserver" ""
- ExecShell "open" "$INSTDIR\${PRODUCTNAME}.exe \regserver" ""
- Push "$INSTDIR\${PRODUCTNAME}.exe"
Call AddSharedDLL
- RegDll "$INSTDIR\${PRODUCTNAME}.exe"

Nothing worked.

I'm sure there must be a way to solve this (by now I'm running a batch file - doesn't look very nice).

Anyone ANY ideas?


Use Exec instead of ExecShell.


Well I just forgot to put it in the list - I tried that also but it seemed that no parameters were accepted, one message like "file not found" or similar appeared.
It seemed windoze thought that "C:\myActiveX.exe /regserver"
is only the path to the file and not a path and a parameter. There fore I tried 'ExecShell'.

But when you tell me it works like that you probably have tried it out, it worked and you can tell me what my fault was ?

=>> one correction by the way:
ExecShell "$INSTDIR\${PRODUCTNAME}.exe" "\regserver"
has been my try


Of course you do have to put quotes around a filename with spaces.

ExecShell '"$INSTDIR\${PRODUCTNAME}.exe" /regserver'


Sorry, no.
It won't do.
I think I nearly tried everything around it, quoted, unquoted, $\"-quoted, with inner and/or with outer quotes, with '- an with "-characters; for being sure I just tried your example again.
It won't do.
Are you sure you have been succesfully registering an VisualBasic-ActiveX-Exe doing it that manner?


btw. neither Windows ME nor Windows 2000 seem to work with this


No, I have never registered a VB ActiveX EXE, I just explained you how to use Exec.

It it works fine when you are using the Windows console it will work fine this way too.


Did you try this?

ExecShell 'cmd /C "$INSTDIR\${PRODUCTNAME}.exe" /regserver'


That will make absolutely no difference and it won't work on Win9x.


oh yeah, sorry, I didn't see the OS. please ignore my post.


Originally posted by Joost Verburg
Of course you do have to put quotes around a filename with spaces.

ExecShell '"$INSTDIR\${PRODUCTNAME}.exe" /regserver'
Joost if you use ExecShell shouldn't the command look like this?
ExecShell "open" "$INSTDIR\${PRODUCTNAME}.exe" "/regserver"

Vytautas

Yes, I already said that Exec should be used but I copied the wrong line.

ExecShell > Exec


Well, thanks to all for wasting their time with this problem.
It's embarassing (and no one will belive me) - my box seems to have had bad days, today it works like Joost said. Everything is behaving like one would expect it as if nothing has been happening.
Again, thank you for your help, it really didn't work yesterday, I promise not to get on anybodys nerves again...