Author Topic: Inno Setup  (Read 3284 times)

0 Members and 1 Guest are viewing this topic.

ronjonp

  • Needs a day job
  • Posts: 7531
Inno Setup
« on: January 26, 2005, 12:21:56 PM »
I wasn't sure where to put this one......but do any of you know how to make  inno setup check and see if a certain file exists (unins000.exe) and if it does run the uninstall before the new install takes place?

Thanks,

Ron

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

hendie

  • Guest
Inno Setup
« Reply #1 on: January 27, 2005, 04:19:22 AM »
Ron,
get a hold of ISTool from http://www.istool.org/default.aspx/ ~ it adds a much better interface to Inno and has additional functionality.

I reckon it should be possible using the Code section but at this point I don't know enough about writing the code (I think it's Pascal) to offer much help.

hendie

  • Guest
Inno Setup
« Reply #2 on: January 27, 2005, 05:25:02 AM »
I've been thinking about this one.. what is the reason to run the uninstall ? couldn't you just set the flags to overwrite the original files ?
If the purpose is to remove some files not included in your new version, you could include them and set the flag to "deleteafterinstall"

don't know if this would be feasible or not..
Create your Program setup exe as normal.
Create another setup exe with the unins000.exe and set the flag to "onlyifdestfileexists" then
In the Install Run section add the file and set the flag to "skipifdoesntexist"
Now add your first setup exe and set the flag to "Waituntilidle"
Now specify that file in the Install Run section after the unins000.exe

A setup within a setup if you like.
My theory is that when you run it, the unins000 file will only be installed if it is already there. If it is there, then it wil be overwritten with the "new" unins000 and then run, thereby uninstalling the original files.
Once the uninstall is complete, your new install should run

If it doesn't already exist, then the file will be skipped and your new setup will be installed and run.


does that make sense ? (I haven't tried it so I could be talking absolute crap)

ronjonp

  • Needs a day job
  • Posts: 7531
Inno Setup
« Reply #3 on: January 28, 2005, 06:24:21 PM »
Hendie,

Thanks for the reply. I think I'm just gonna overwrite all files in my install rather than make it difficult.

Thanks,

Ron

P.S. I couldn't function without ISTool :D

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC