NAV 2017 client upgrade script

Hello all!

Microsoft keeps updating our beloved NAV regularly. They provide both application hotfixes and platform hotfixes. Since there is plenty of blog posts about object update and merge already, this blog post concentrates on how to update the client binaries, a.k.a. platform.

In the old days, Microsoft provided hotfix -folders named as ADCS, Applicaton Server, Classic Client etc, from where NAV technician then copied the contents to installed folders, for example Classic Client contents to C:\Program Files (x86)\Microsoft Dynamics NAV\60\Classic -folder.

Since 2015 CU01, Microsoft declined this practise, and only publishes zipped installation DVD image where technicians then use Jorg's script Copy-UpdateFilesToBatchDirectory.ps1 to create UPDATEFILES folder with similar folder structure as the old fashioned way.

I used to exploit this script a lot, since I am responsible of our development environments. However, in time this script has become a bit outdated because Cumulative Updates contain now more files and folders that have to be copied in other folders than the standard NAV installation folders. Especially this was true with NAV 2016 CU07 and its NavSip.dll, which caused me some gray hairs...

The original script has been modified by many NAV technicians, and for example "removing the unnessessary files" part has ben modified heavily. For example the help files have been updated and the original script ignored them. Microsoft employees have later blogged more about upgrading the clients, for example this blog post gives nice hints how to do the trick with PowerShell.

For these reasons I decided to write a script of my own. And since I am not (yet) a PowerShell guru, I wrote it in as an old fashioned .CMD script. All you have to do is unzip the installation folders from CU package, add the unzipped folder name to the script, and run it as an administrator.

It first checks it is indeed run as an administrator, deletes the Zone information from the update files to prevent Blocking issue (by using sysinterals streams.exe, which is not included for copyright reasons), does some other checks (mainly x32/x64 tests), shuts down the services and then copies new files from the installation folders to installed folders. Pretty straightforward.

I will provide my script for your convenience, and you are free to use and modify it as you please. Should you spread it around, please leave information about the original author in the script - both for the praise and blame :) If you have any improvement suggestions or other comments, the space below is at your disposal!

And remember, I take no responsibility if you manage to destroy some environment with this script ;)
Comment List