visual-studio 在 VS 2008 安装项目中设置制造商
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/272717/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Setting the manufacturer in a VS 2008 Setup Project
提问by Mark Meuer
I have a windows setup project that installs a service. All works well except for one thing: The default directory offered to the user during install is of the form "C:\Program Files\Microsoft\ProgramName". I am trying to modify this so that instead of "Microsoft" we would have our company's name.
我有一个安装服务的 Windows 安装项目。除了一件事之外,一切都很好:安装期间提供给用户的默认目录的格式为“C:\Program Files\Microsoft\ProgramName”。我正在尝试修改它,以便我们公司的名称而不是“Microsoft”。
I found the application folder property of the setup project, and it has a DefaultLocation property of "[ProgramFilesFolder][Manufacturer][ProductName]". So, it looks like all I need to do is set the "Manufacturer" property and I'll be all set. However, I can not find a way to set this property! I had hoped it would take it from the company name in the AssemblyInfo of the primary output project, but it did not.
我找到了安装项目的应用程序文件夹属性,它的 DefaultLocation 属性为“[ProgramFilesFolder][Manufacturer][ProductName]”。所以,看起来我需要做的就是设置“制造商”属性,我就可以了。但是,我找不到设置此属性的方法!我曾希望它会从主要输出项目的 AssemblyInfo 中的公司名称中获取它,但它没有。
I could remove "[Manufacturer]" from the DefaultLocation and replace it with our literal company name, but that seems like a hack.
我可以从 DefaultLocation 中删除“[Manufacturer]”并将其替换为我们的字面公司名称,但这似乎是一个黑客。
How do I set the Manufacturer name?
如何设置制造商名称?
Note that I am not using a full-blown WiX project. I have simply added a windows setup project to my solution.
请注意,我没有使用成熟的 WiX 项目。我只是在我的解决方案中添加了一个 Windows 安装项目。
Thanks in advance for any help.
在此先感谢您的帮助。
回答by Rob Prouse
Click on your setup project in Visual Studio, open the Properties and you will notice that there are a number of Properties that you can set like Manufacturer, SupportURL, etc.
在 Visual Studio 中单击您的安装项目,打开属性,您会注意到有许多属性可以设置,例如制造商、SupportURL 等。
回答by Frank Schwieterman
Note if you're confused/frustrated doing this seemingly trivial thing: if you open properties by right-clicking on the project and clicking "Properties" in the right-mouse menu, you will get the wrong dialog box. You need to select the project, but then navigate to the properties tag. One way to navigate to the properties tag is from the "View" menu, select "Properties Window".
请注意,如果您在做这件看似微不足道的事情时感到困惑/沮丧:如果您通过右键单击项目并单击鼠标右键菜单中的“属性”来打开属性,您将看到错误的对话框。您需要选择项目,然后导航到属性标记。导航到属性标记的一种方法是从“查看”菜单中选择“属性窗口”。

