Monthly Archives: December 2016

c# – Get Product Version and Assembly Version of external application

Sometimes it is needed to know version of external application’s  Product Version or Assembly Version. It is actually very easy task. using System; using System.Diagnostics; using System.Reflection; namespace GetAppVersion { class Program { static void Main(string[] args) { if (args.Length == 0) { System.Console.WriteLine(“Please enter program path.”); return; } try { var versionInfo = FileVersionInfo.GetVersionInfo(args[0]); Console.WriteLine($”ProductVersion: {versionInfo.ProductVersion}”);… Read More »

c# – Windows File Explorer extension for creating url shortcuts – Part 2

In previous post we stated extension for creating url shortcuts. Now it is time to create actual file explorer menu items and get the basics working. First let’s create small class what will deal with needed registry entries. Creating contect menu items is quite simple, just two entries in registry.   using Microsoft.Win32; using System.Windows.Forms; namespace… Read More »

5 cents hint – msi installer is not updating exe or additional dll-s

After struggling with the issue found simple solution. Open the AssemblyInfo.cs file for your project, and change AssemblyVersion to [assembly: AssemblyVersion(“1.0.*”)] then the assembly version information is automatically updated each time you build the project. Then comment out or remove the AssemblyFileVersion entry from the same file, so the file version defaults the same as… Read More »