我在这里读了关于汇编,文件和汇编信息版本的线程。发布版本与大会(等)版本
我想知道在那里发布版本相符。结果...
string thisAppsVersion = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString();
......似乎是的AssemblyVersion。到现在为止,我一直在使用该版本的发布与部署类:
ApplicationDeployment deployment = ApplicationDeployment.CurrentDeployment;
Version thisAppsVersion = deployment.CurrentVersion;
...但除非安装了应用程序,这是不可用。我喜欢它如何选择自动增加版本。
有没有办法在没有网络部署的情况下获取发布版本?它应该是应用版本的“公开面孔”吗?
Example: UI Version (twisted from Publish Version)
提前感谢!
Gregg
Hi Dudu,谢谢你的明确解释。这很好地澄清了事情! – MrGreggles 2010-01-20 17:35:32
有没有办法让他们自动匹配? – 2017-03-15 16:06:35