GetVersion in nice label 2019

Label printing integration (NiceWatch middleware and ActiveX programming interface)

Moderators: Georges, milos, NiceLabel Support Team

Post Reply
hashitha88
Newcomer
Posts: 3
Joined: Wed Apr 15, 2020 5:20 pm

GetVersion in nice label 2019

Post by hashitha88 » Fri Apr 24, 2020 2:14 pm

we are currently using nicelabel 5 SDK, it has a method call GetVersion() to check NiceLabel version.
Now we are migrating to Nicelabel 2019 .NET SDK ,what is the similar method that i can use to get the installed niceLabel version number using C#.

User avatar
Mytch
NiceLabel Support
NiceLabel Support
Posts: 153
Joined: Fri Jul 13, 2018 10:26 pm
Location: Milwaukee, Wisconsin
Contact:

Re: GetVersion in nice label 2019

Post by Mytch » Wed Apr 29, 2020 2:40 pm

hashitha88,

As you have already found, GetVersion() is no longer supported. Maybe you can do something like this:

Code: Select all

FileVersionInfo fileInfo= FileVersionInfo.GetVersionInfo(@"C:\Program Files\NiceLabel\NiceLabel 2019\bin.net\SDK.NET.dll");
This will check file properties of SDK.NET binary for current version (will be the same as installed version of NiceLabel). Of course, this is not actually utilizing NiceLabel API but should accomplish the same goal.

Regards,
Mytch

User avatar
Saso
NiceLabel
NiceLabel
Posts: 2984
Joined: Mon Sep 04, 2006 8:09 am
Contact:

Re: GetVersion in nice label 2019

Post by Saso » Wed Apr 29, 2020 2:55 pm

You can also try a suggestion here:
https://stackoverflow.com/questions/909 ... le-version
Saso Fleiser
Senior Technical Product Specialist

hashitha88
Newcomer
Posts: 3
Joined: Wed Apr 15, 2020 5:20 pm

Re: GetVersion in nice label 2019

Post by hashitha88 » Mon May 04, 2020 9:41 am

Thanks Mytch & Saso, I'll try both.

Post Reply