To help you better we need some information from you.
*** Please fill in the fields below. If you leave fields empty or specify 'latest' rather than the actual version your answer will be delayed as we will be forced to ask you for this information. ***
Product, version and build: PS Studio 2023
Operating system: Windows 10
PowerShell version(s): 5 - latest
*** Please add details and screenshots as needed below. ***
DO NOT POST LICENSES, KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM
I have built a MSI that installs my application. I have also built an 'updated' MSI that is intended to update my app. When I run it on my machine, I receive an error stating that a version of the product is already installed and I must uninstall first. Is there a way to have the 'updated' MSI run and update the application without having to uninstall the first one? I did notice that in the packager menu under 'Execution settings', there is a
Maintenance' option. I assume that is what I'm trying to do. Thank you.
*** Redirected to 'Former and Future Customers - Questions' section: No active maintenance ***
Updated MSI Install
Forum rules
DO NOT POST SUBSCRIPTION NUMBERS, LICENSE KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
DO NOT POST SUBSCRIPTION NUMBERS, LICENSE KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
- Alexander Riedel
- Posts: 8601
- Last visit: Fri Dec 06, 2024 9:05 pm
- Been upvoted: 43 times
Re: Updated MSI Install
Did you increase the version number between installers? If so, from what to what?
Alexander Riedel
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.
-
- Posts: 30
- Last visit: Thu Dec 05, 2024 8:37 am
Re: Updated MSI Install
I did not; both are currently at: 1.0.1.0
If I need to, can you give me an example of what version to change the new to? Thank you.
If I need to, can you give me an example of what version to change the new to? Thank you.
- Alexander Riedel
- Posts: 8601
- Last visit: Fri Dec 06, 2024 9:05 pm
- Been upvoted: 43 times
Re: Updated MSI Install
You can read more here https://learn.microsoft.com/en-us/windo ... d-upgrades
but in essence, you need to increase any of the first three version numbers (major, minor or revision).
The fourth number is usually referred to a 'build' and can be used as an internal tracker. it has no meaning for Windows Installer.
By increasing from 1.0.1.0 to e.g. 1.0.2.0, a new ProductCode is generated with the new MSI file. This is automatic.
(See here for an explanation of all fields: https://www.sapien.com/blog/2023/08/02/ ... t-details/)
As the blog post points out, it is generally helpful to specify the path to an executable with a version resource rather than an actual number.
That way the version used for the MSI corresponds with the version of your application's main executable automatically.
If you do not install any files with a version resource, you have to specify and increase the version number yourself.
When Windows installer detects an increased version number and a new ProductCode it will remove the old version and install the new one.
Hope this helps you.
but in essence, you need to increase any of the first three version numbers (major, minor or revision).
The fourth number is usually referred to a 'build' and can be used as an internal tracker. it has no meaning for Windows Installer.
By increasing from 1.0.1.0 to e.g. 1.0.2.0, a new ProductCode is generated with the new MSI file. This is automatic.
(See here for an explanation of all fields: https://www.sapien.com/blog/2023/08/02/ ... t-details/)
As the blog post points out, it is generally helpful to specify the path to an executable with a version resource rather than an actual number.
That way the version used for the MSI corresponds with the version of your application's main executable automatically.
If you do not install any files with a version resource, you have to specify and increase the version number yourself.
When Windows installer detects an increased version number and a new ProductCode it will remove the old version and install the new one.
Hope this helps you.
Alexander Riedel
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.
-
- Posts: 30
- Last visit: Thu Dec 05, 2024 8:37 am
Re: Updated MSI Install
I will have a read through the links and try that, thanks. Will it also re-run the custom actions, and do I need the previously mentioned 'Maintenance' setting checked for one of them? Thanks.
- Alexander Riedel
- Posts: 8601
- Last visit: Fri Dec 06, 2024 9:05 pm
- Been upvoted: 43 times
Re: Updated MSI Install
It will run the same custom actions as on any install. Maintenance is a different animal.
"Maintenance actions within an MSI (Microsoft Installer) package run whenever a repair operation is initiated on the installed software, which can be triggered through the "Add or Remove Programs" control panel, by right-clicking the application and selecting "Repair," or by using the "msiexec" command with the "/f" parameter to perform a repair installation. "
"Maintenance actions within an MSI (Microsoft Installer) package run whenever a repair operation is initiated on the installed software, which can be triggered through the "Add or Remove Programs" control panel, by right-clicking the application and selecting "Repair," or by using the "msiexec" command with the "/f" parameter to perform a repair installation. "
Alexander Riedel
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.