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

DoInstall problems


11 replies to this topic

elektrik

elektrik
  • Full Members
  • 12 posts

Posted 03 January 2002 - 20:38

Hi.  I'm having a problem with the DoInstall function in InstallShield Professional 6.31.  My issues are listed below:

Goal:  To give the user the option to have the current setup program "update" an older version of the application created by a previous Installshield script (also 6.31). by running the old install program in "uninstall mode" to remove it, and to continue installation AFTER the old has been removed.

Steps to achieve goal:

-I check to see if there is an old version of the file
even installed and if so:
-Check the version number.  If it is older than
the one installing, I then show a sprintfbox
giving them the option to upgrade. If they select
"yes" I then call the DoInstall function to call
the other setup currently on the system in
"uninstall mode".  Any other response proceeds
with setup normally.
-If there is no old version of the file, I proceed with
setup normally

Problems encountered:

-I'm either encountering a message that says "access is
denied" from Windows (derived from formatting the negative
number using FormatMessage), or running (one setup, not sure
whether new or old!) in Maintenance mode.
-When the one setup does run, the "new" setup does not
continue to run as it should after finishing the DoInstall
command, which defeats the purpose of giving the user the
option to use the new setup to uninstall the old version

All I want to do is achieve the goal stated above, so if I'm doing this incorrectly, feel free to let me know-I'm open to doing things a different way.  The only thing I'd like to do is achieve the goal using the script only.

Any help would be appreciated.

Thanks!


elektrik

elektrik
  • Full Members
  • 12 posts

Posted 04 January 2002 - 19:01

I take it no one is using DoInstall eh?  =]

Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 04 January 2002 - 19:35

I don't, I use LaunchAppAndWait, but actually what's going on is most people are still on a holiday break.  If you've noticed this forum's been rather dead this week.

lasenbby

lasenbby
  • Members
  • 744 posts

Posted 04 January 2002 - 21:02

I use launchappex for everthing except calling another install; because I have seen inconsistencies on w2k machines and it will ocasionally hang calling the subinstall.  I use IS' lauchappandwait for calling subinstalls.

Another thing I do is, rename (not delete) the uninstall regkey for the sub install and this makes the subinstall always run in onfirst mode.  If the subinstaller finished ok, then delete the renamed key and there is a new one made by the sucessful install.  If it did not finish correctly, rename it back so there is a way to uninstall what is out there now.

(I am horrified to hear that the 6.31 doinstall functionality still does not work correctly.  I have come to believe it is not how much IS you know that makes you a guru, it's how many of the "claimed" IS functionalities that don't work that you can sucessfully workaround.)


elektrik

elektrik
  • Full Members
  • 12 posts

Posted 04 January 2002 - 21:40

Thanks guys for the reply =]

Taco:  LaunchAppAndWait isn't a viable solution for me, since it causes an error message when one InstallShield script is called from another.

Lasenbby:  Haven't tried Launchappex yet-I'll try that next (I've just about tried every other one, including LaunchApp, LaunchAppAndWait, etc.)

It's interesting that you renamed the uninstall  regkey instead of deleting it.  I've tried deleting the old reg entry, but I still come up in maintenance mode.  I have created a workaround for my problem since my original post, but it's only a bandage solution (Basically what I've done is modified my code at "OnBegin" to check for the file version of the old app to be 'updated' and then set a global variable; Then I delete the reg entries for old installshield, whack the targetdir and disk1target, and then put an "if" statement in MaintFirstUI that checks for the value of that global variable.  Then I use "componentreinstall" to *update* the files, and it works for my specific program).  What I'm worried about though is "other" projects I have to do with my company that will eventually have multiple components, and since ComponentReinstall ONLY reinstalls the option that was selected, I don't know that it will work (in thinking through my previous statement, it may yet work, since I'm pretty much manually wiping the old installation out of existence, but I STILL don't like having to *ramrod* it through this way).

Oh well!


Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 04 January 2002 - 23:25

launchappex is not defined in the help nor is it an availble function in IS 6.31.

Am I missing something here?


elektrik

elektrik
  • Full Members
  • 12 posts

Posted 04 January 2002 - 23:29

Maybe  custom code?  I haven't even checked to see if this was a function in IS 6.31 (and judging by your response Taco, I guess it isn't!  LOL!)

runningquicklynowher

runningquicklynowher
  • Members
  • 20 posts

Posted 05 January 2002 - 00:06

Quote
Quote: from TacoBell00 on 10:25 pm on Jan. 4, 2002
launchappex is not defined in the help nor is it an availble function in IS 6.31.

Am I missing something here?


It is a custom function found on this site.  I think it is in the IS5/6 Tools & Tips section, but off the top of my head I don't remember exactly where.  It works great.

elektrik

elektrik
  • Full Members
  • 12 posts

Posted 07 January 2002 - 19:25


>It is a custom function found on this site.  I think it is in the IS5/6 Tools & Tips section, but off the top of my head I don't remember exactly where.  It works great.


I'll try to find it-InstallShield tech support is not being very helpful...


elektrik

elektrik
  • Full Members
  • 12 posts

Posted 07 January 2002 - 22:45

Quote
Quote: from runningquicklynowher on 11:06 pm on Jan. 4, 2002
Quote
Quote: from TacoBell00 on 10:25 pm on Jan. 4, 2002
launchappex is not defined in the help nor is it an availble function in IS 6.31.

Am I missing something here?


It is a custom function found on this site.  I think it is in the IS5/6 Tools & Tips section, but off the top of my head I don't remember exactly where.  It works great.

Well, after looking at this sample code, this is basically the same as the built-in "LaunchAppAndWait" function with a few additional functions, and since I can't use this function this won't be helpful....

Any other suggestions (kinda desparate)


(Edited by elektrik at 5:46 am on Jan. 8, 2002)

(Edited by elektrik at 5:47 am on Jan. 8, 2002)


Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 09 January 2002 - 18:01

Are you sure you are using 6.31? Calling one setup from another with LaunchAppAndWait should work in that version but wasn't possible before.

elektrik

elektrik
  • Full Members
  • 12 posts

Posted 09 January 2002 - 19:49

Quote
Quote: from Stefan Krueger on 1:01 am on Jan. 10, 2002
Are you sure you are using 6.31? Calling one setup from another with LaunchAppAndWait should work in that version but wasn't possible before.

Ya, I'm positive.