C# How to correctly set assembly title for Windows 8 Task Manager?

醉酒当歌 提交于 2019-12-11 14:15:14

问题


I've set the title & assembly info of my C# Winforms executable as follow:

[assembly: AssemblyTitle("Widgets Galore")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Widgets Inc")]
[assembly: AssemblyProduct("Widgets Galore")]
[assembly: AssemblyCopyright("Copyright © Widgets Inc 2012")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

...

MainForm.Text = "Widgets Galore by Widgets Incorporated";

...

// Compiles to: widgets.app.exe

In Windows 7 Task Manager, it correctly shows the process as the main form title:

"Widgets Galore by Widgets Incorporated"

However in Windows 8 Task Manager, it incorrectly shows the executable name, with a sub item:

"widgets.app"
    |--"Widgets Galore by Widgets Incorporated".

I see plenty of other applications listed with a friendly name in the Windows 8 Task Manager, and would like to see my app do the same.

How can I force W8 to do a friendly name for my app?

-Brendan


回答1:


Through trial and error I found that Windows 8 Task Manager shows the exe name regardless of [AssemblyTitle], IF your file is not digitally signed. I assume this is a security measure. Solution: digitally sign.



来源:https://stackoverflow.com/questions/18647314/c-sharp-how-to-correctly-set-assembly-title-for-windows-8-task-manager

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!