I used this method to get version number of my XNA game:
public static string GetVersionNumber()
{
var asm = Assembly.GetExecutingAssembly();
var parts = asm.FullName.Split(',');
return parts[1].Split('=')[1];
}
But on iOS, it always returns “1.0.0.0”, which is different from the verion number set in the Info.plist file.
I googled a bit and found that NSBundle.MainBundle.InfoDictionary[“CFBundleVersion”] should return the version number, but I can’t access NSBundle in the solution. It seems to be Xcode and obj-c related… =(