devxlogo

Spread Upgrades Over the Network

Spread Upgrades Over the Network

I design VB applications for approximately 300 employees in a networked environment. It’s difficult to keepthose PCs up to date with the most current version of an app, so I use VB’s auto-incrementingversion-numbering feature to have the app test if a newer version is available when it launches.Set the app to auto-increment when it’s compiled. Store the setup/upgrade files on a networked drive (besure to use the UNC path rather than drive letters), and include an uncompressed INI file that lists thenewest version available. Then embed this code into the Form_Load event:

 Open IniFile$ For Input As #1Line Input #1, sUpgradeVersion$Close #1If sUpgradeVersion > (Format(App.Major, "00") & "." & _        Format(App.Minor, "00") & "." & _        Format(App.Revision, "0000")) Then                ' shell out to networked upgrade                 ' installation        End     End If

If the version in the networked INI file is greater than that stored within the running app, the app launchesthe upgrade program off the network and exits, so all files can be upgraded. This works especially wellwhen you’re in the early stages of a rollout and need to distribute multiple small incremental patches over anumber of days.

devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist