Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Need help with IS 6.x Uninstall


10 replies to this topic

shanksworthy

shanksworthy
  • Members
  • 8 posts

Posted 23 August 2002 - 05:02

If this question is too basic, I apologize in advance -- I'm only familiar with IS 5.x...

My problem is, we've got an install script that was created in IS 5.x, and now we're migrating it to 6.x.  Everything works, except for the uninstall!

For our 5.x uninstall, we use a custom uninstall app called "uninstall.exe", which is launched from the Uninstall section of the registry.  So the value for "uninstall string" in the Uninstall registry key is "c:\program\uninstall.exe", instead of
"IsUninst.exe -fc:\program\uninst.isu".  "Uninstall.exe" does a few necessary cleanup functions, then launches the UnInstallShield script like this:

"isuninst.exe -fc:\program\uninst.isu"

My question is, with IS 6.x, what should I replace the above line with?  Apparently, .isu files have been replaced with .ilg files -- will isuninst.exe still work on these files?  If not, then what should I do?

Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 23 August 2002 - 05:41

Welcome to IS6 and yes, that's all changed.  The correct command can be taken from the following registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\<InstallGUID>\UninstallString

Where InstallGUID is the GUID number of your IS6 project.  It's accessible from the Application tab of the Project | Settings dialog.

However, it sounds like you may be already overwriting that with your custom command.  You should instead backup the original string entry under a different name which your alternative application can just reference.
user posted image

shanksworthy

shanksworthy
  • Members
  • 8 posts

Posted 23 August 2002 - 18:02

Thanks for your quick response.

The problem is, I actually don't have access to 6.x, so I can't study the string it places under the <app guid> registry key.  Rather, I've got a client who is trying to figure out how to migrate the 5.x install I built for her, to 6.x.  So I'm trying to help her out, virtually blindfolded. :-)

If you could answer the following questions, it would be a great help to me;

1. How does 6.x name the uninstall script? (In IS 5.x, it was "*.isu").  

2. What application actually _does_ the uninstallation? (In IS 5.x, it was "IsUninst.exe").



Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 23 August 2002 - 19:05

Yeah, I thought about giving you an example, but decided that probably wouldn't be necessary.  Guess I was wrong.

Here's the contents of an IS 6.31 UninstallString:
"RunDll32 C:\PROGRA~1\COMMON~1\INSTAL~1\engine\6\INTEL3~1\Ctor.dll,LaunchSetup "C:\Program Files\InstallShield Installation Information\{CB3BF840-61FD-4E54-8D9B-8974457166DC}\Setup.exe" -l0x9  -uninst "

This will in turn reference an setup.ilg (InstallShield Log File) which sits along side the executable.

To find the GUID then, first get the display name from Add/Remove Programs and then search for that string in the Uninstall area of the registry.
user posted image

shanksworthy

shanksworthy
  • Members
  • 8 posts

Posted 23 August 2002 - 19:48

Ah, so the replacement for "IsUninst.exe" is actually "Setup.exe -uninst", correct?  

Would it work if I just placed "C:\Program Files\InstallShield Installation Information\{CB3BF840-61FD-4E54-8D9B-8974457166DC}\Setup.exe" -l0x9  -uninst" into the Uninstall String, instead of that whole Rundll32 thing?  (What does Ctor.dll do anyway?)

Also, when is that .ilg file created?  In IS 5.x, it's created during the actual install.  In IS 6.x though, I get the impression that it's created during compile.

(Sorry for the barrage of questions -- I'm just trying to amass as much knowledge as I can before the next conference call :-)

Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 23 August 2002 - 22:25

Yes, "Setup.exe -uninst" is basically the replacement.  However, I honestly can't say if just using it would be sufficient.  I also handle uninstalls a little different, but in the end I do make the real call as is.  I've not tried alternative formats.

No, the ILG file in IS6 is also created during installation as that contains the machine's setup information.
user posted image

shanksworthy

shanksworthy
  • Members
  • 8 posts

Posted 23 August 2002 - 23:41

Cool.  OK, so I'm going to suggest that she do the following:

1. Replace the Uninstall String value in HKLM\Software\Microsoft\Windows\CurrentVersion\Uninstall\<InstallGUID> with "c:\program\uninstall.exe"

2. Replace the code in Uninstall.exe which was previously "isuninst.exe -fc:\program\uninst.isu" with "RunDll32 C:\PROGRA~1\COMMON~1\INSTAL~1\engine\6\INTEL3~1\Ctor.dll,LaunchSetup "C:\Program Files\InstallShield Installation Information\{CB3BF840-61FD-4E54-8D9B-8974457166DC}\Setup.exe" -l0x9  -uninst"

Of course, this is rather simplified.  In actual fact, I'd pass that into uninstall.exe as a command line argument.  So my Uninstall String value would actually be more like
"c:\program\uninstall.exe /RunDll32 C:\PROGRA~1\COMMON~1\INSTAL~1\engine\6\INTEL3~1\Ctor.dll,LaunchSetup "C:\Program Files\InstallShield Installation Information\{CB3BF840-61FD-4E54-8D9B-8974457166DC}\Setup.exe" -l0x9  -uninst".

Hope this works!  Thanks for your help.

Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 24 August 2002 - 02:47

Hold on, I think you're missing something here.

That command line argument needs to be the one generated by IS.  The one I provided here was just a sample.  Yours will most definitely vary.  At a minimum, the GUID portion of "{CB3BF840-61FD-4E54-8D9B-8974457166DC}" will be different, but the Program Files location may also be different depending on the system.

This why I've brought up the whole GUID concept on a few different occassions and have given you ways to determine it.

This is also why I've also backing up the default uninstall command.  Especially since you may have problems trying to pass such a long command line.
user posted image

shanksworthy

shanksworthy
  • Members
  • 8 posts

Posted 24 August 2002 - 03:05

Yikes, no... I was just using that as an example for the sake of simplification.  The string I pass as a parameter into uninstall.exe will definitely be the one generated by IS 6.x.  Don't worry,  I completely understood you. :)

From a coding perspective, it would simply be a matter of waiting until after IS writes the UninstallString value, then getting that value and appending it to the string "uninstall.exe ".  Then I'd write that whole value back to the registry.  So UninstallString would then look something like "c:\program\uninstall.exe /RunDll32 C:\PROGRA~1\COMMON~1\INSTAL~1\engine\6\INTEL3~1\Ctor.dll,LaunchSetup "C:\Program Files\InstallShield Installation Information\{CB3BF840-61FD-4E54-8D9B-8974457166DC}\Setup.exe" -l0x9  -uninst" (substituting the latter portion for whatever IS has generated).  This new UninstallString value would serve to pass that IS-generated value into uninstall.exe as a command-line parameter, which would then in turn execute that UninstallString value verbatum.

In theory it all makes sense -- now it's just a matter of crossing my fingers and hoping it works  ???

Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 24 August 2002 - 03:51

Okay good.  I'm glad you understand.

Yes, that theory make sense.  It's just that the command line has spaces, quotes, etc., so I'm still not sure your uninstall.exe will properly receive it as is.  Like you said though, you'll just have to put your theory to the test then and see what happens.
user posted image

shanksworthy

shanksworthy
  • Members
  • 8 posts

Posted 24 August 2002 - 03:55

Yeah, I'll probably have to put quotes around the whole argument so that it's not misinterpreted as multiple arguments due to the spaces.  I'll let you know how it works out.