Update vs install

35 views
Skip to first unread message

Edgar Prothero

unread,
May 19, 2024, 2:46:28 PMMay 19
to inno...@googlegroups.com
Hello,

I have created a program that I may want to update periodically.  I was wondering how I can make my setup utility auto detect whether or not the original program is in place and just perform the movement of the files needed to be updated?  I would also like to be able to execute a program that will extract the settings for the original copy so that the user does not have to manually reset their settings.  I have the code already written and fully tested - I just need to write the setup / update portion with Inno.  Any ideas?

Ed Prothero
Michigan 

Jernej Simončič

unread,
May 19, 2024, 4:25:05 PMMay 19
to Edgar Prothero on [innosetup]

On Sunday, May 19, 2024, 20:30:52, Edgar Prothero wrote:


I have created a program that I may want to update periodically.  I was wondering how I can make my setup utility auto detect whether or not the original program is in place and just perform the movement of the files needed to be updated?  I would also like to be able to execute a program that will extract the settings for the original copy so that the user does not have to manually reset their settings.  I have the code already written and fully tested - I just need to write the setup / update portion with Inno.  Any ideas?

In general, there's no difference between install and update – the same installer can do both, and you don't have to do anything special for updates to work.

Regarding settings: the installer normally shouldn't touch any areas that contain settings (this is especially true if your installer runs elevated, and the program is installed to Program Files). The settings should be written to user-specific areas (either %APPDATA%/%LOCALAPPDATA% or HKCU in Registry, neither of which should be touched by the installer, because the user installing your program may not be the user that will be running it afterwards).


-- 
< Jernej Simončič ><><><><>< https://eternallybored.org/ >


Good salesmen and good repairmen will never go hungry.
       -- Schenk's First Principle of Industrial Market Economics
Reply all
Reply to author
Forward
0 new messages