08-03-2017 07:55 AM
Hi,
How can I replace the older labview exe file with a new exe file, which avilable on server, programatically.
Means I am giving an option to the user to check for any updates in the softwre.
By comparing the old version and new version from .ini file in both local and server pc i can find out if there any new release. But how can I replace the exe, if user wish to update, programatically.
Solved! Go to Solution.
08-03-2017 08:09 AM
I do this by creating an update EXE. At some specified interval (daily, weekly), "main" will check an update folder for a new version. If it finds one, "main" will call "update" and main exits. "Update" will archive the existing "main" and replace it with the new "main". The new "main" is opened and "update" exits.
08-03-2017 08:19 AM
Ok I ll do the same and check.
08-03-2017 08:44 AM - edited 08-03-2017 08:46 AM
Another way to do it eliminates one step. I just saw in another thread this week where a person asked a similar question. LabVIEW Applications Updates
When you call your .exe, you actually just call a launcher program. It does the checking, if it finds nothing new (or can't do the check because of some error such as the network is down) it launches the executable existing on your PC. If the check finds a newer one is available, it copies that over from the server to your PC and launches that.
So instead of Program (checks) >> Updater >> Program
it is Launcher (checks) >> Program
Your launcher program can have a nice splash screen.
08-03-2017 09:03 AM
Yeah, that is a good idea as well. If you want something fully featured, you would probably have a combination of the two, with also a manual check for updates initiated by the user. Sometimes, production line software doesn't get shutdown and restarted often enough and frequent updates may go unnoticed without some regular interval check.
08-04-2017 12:08 AM
Yea.. Both are good ideas..
But In my case we have to give the user a button for software update check.
So I have to launch the main software first and launch the update exe if user want to update..
I will try out this method.. come back..
Thanks for the support
08-04-2017 01:01 AM
Hi Harisam,
But In my case we have to give the user a button for software update check.
So I have to launch the main software first…
Why do you need to start your "main software" to present a button to the user?
I also use this "Launcher/Check" -> "start main" approach: when the launcher notices an update it presents a dialog to the user with two buttons "Update now" or "Postpone the update"…