Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I create a custom Property for my assembly?

How can I create a custom property for my .Net assembly which would then be visible under the Details tab in Windows explorer?

Something to sit parallel with "File Description", "Type", "Product Version"... etc

Update: To quote my comment to Lars ... "Whilst I would have liked to do this from within Visual studio, that is certainly not my priority. Actually I hope to integrate any solution into an existing nant build process. So affecting the assemblies post compile is entirely acceptable. Have you ever heard of such a tool?"

Further Update: I'm not sure if what I'm talking about is an attribute or not, to clarify a little what I would like to creat in an entry in the following property page...

alt text

like image 222
Rory Becker Avatar asked Oct 10 '08 15:10

Rory Becker


1 Answers

Your compiler does not support it. AssemblyFileVersionAttribute and all work because the compiler generates a win32 resource in your assembly called VERSIONINFO with that information in it. That is what windows is reading. Other attributes are just saved as metadata along with your code.

You could make a tool to change the VERSIONINFO resource after you compile.

like image 89
Lars Truijens Avatar answered Oct 09 '22 08:10

Lars Truijens