开发者

How can you edit the description, author, etc. for the built exe in MS visual C# 2008?

I have finished my program in c#, hit build solution, and gra开发者_运维技巧bbed the exe out of the bin folder in my project directory. I noticed the description under the filename was "WindowsFormApplication1". I browsed briefly through any fields in the solutions explorer I might change, but nothing worked. Am I doing the right thing to release my program, and/or where can you change that description? I would like to just pass the exe around.


Two methods.

  1. Right click on project=>properties=>Application=>Assembly Information...

  2. Solution Explorer=>Project=>Properties folder=>AssemblyInfo.cs


You can change them in the project properties at Application -> Assembly Information....
If you're concerned about the meta data in general, you may want to disable the pdb at Build -> Advanced... -> Debug Info or the assembly will contain the full path to the .pdb file, wich usually contains the user name.


I'd like to add that in case you're working with multiple projects in one solution, one could create a separate build properties file. This way you don't need to set the properties per project.

  1. Create the file Directory.Build.Props in the solution folder.

  2. Add the following properties

    <Project>
        <PropertyGroup>
            <Version>1.0.0.0<Version>
            <AssemblyVersion>1.0.0.0</AssemblyVersion>
            <FileVersion>1.0.0.0</FileVersion>
            <Company>Stack Exchange Inc.</Company>
            <Authors>Jeff Atwood, Joel Spolsky</Authors>
            <Copyright>user contributions licensed under cc by-sa. rev 2020.10.26.37891</Copyright>
        </PropertyGroup>
    </Project>
    
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜