how to set a assembly's properties without the use of a GUI

  • Thread starter Thread starter Marcus
  • Start date Start date
M

Marcus

I want to set the Description of my .exe file (it is a .NET
assembly).
You know that description that is seen in Windows Task Manager process
tab. Almost every running process has got one. They can be a whole
sentence explaining what the process is about.

I need a way of setting this description of my .exe without any GUI. I
need it to be set from a command line tool or something alike.

Is there a tool like that? Maybe something built into Windows?
 
I want to set the Description of my .exe file (it is a .NET
assembly).
You know that description that is seen in Windows Task Manager process
tab. Almost every running process has got one. They can be a whole
sentence explaining what the process is about.

I need a way of setting this description of my .exe without any GUI. I
need it to be set from a command line tool or something alike.

Is there a tool like that? Maybe something built into Windows?

That information is stored in the executable.

For example in assembly language, a resource file like this is used.
Your programming language should have something similar.

#define APP_VERSION_INFO 1 // {{ define at the top your .RC
file }}

// example version resource
APP_VERSION_INFO VERSIONINFO
FILEVERSION 1,1,0,0
PRODUCTVERSION 1,1,0,0
FILEFLAGSMASK 0x17L
FILEFLAGS 0x0L
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
{
BLOCK "StringFileInfo"
{
BLOCK "040904b0"
{
VALUE "CompanyName", "Siege_Works"
VALUE "FileDescription", "Delete Windows XP Temporary
Directories"
VALUE "FileVersion", "1.0"
VALUE "InternalName", "Del_Tmp_Dirs"
VALUE "LegalCopyright", "© Quality Home Repairs"
VALUE "OriginalFilename", "Del_Tmp_Dirs.exe.exe"
}
}
BLOCK "VarFileInfo"
{
VALUE "Translation", 0x409, 1200
}
}
 
That information is stored in the executable.

For example in assembly language, a resource file like this is used.
Your programming language should have something similar.

#define APP_VERSION_INFO    1     // {{ define at the top your .RC
file }}

// example version resource
APP_VERSION_INFO VERSIONINFO
    FILEVERSION 1,1,0,0
    PRODUCTVERSION 1,1,0,0
    FILEFLAGSMASK 0x17L
    FILEFLAGS 0x0L
    FILEOS 0x4L
    FILETYPE 0x1L
    FILESUBTYPE 0x0L
{
    BLOCK "StringFileInfo"
    {
        BLOCK "040904b0"
        {
            VALUE "CompanyName", "Siege_Works"
            VALUE "FileDescription", "Delete Windows XP Temporary
Directories"
            VALUE "FileVersion", "1.0"
            VALUE "InternalName", "Del_Tmp_Dirs"
            VALUE "LegalCopyright", "© Quality Home Repairs"
            VALUE "OriginalFilename", "Del_Tmp_Dirs.exe.exe"
        }
    }
    BLOCK "VarFileInfo"
    {
        VALUE "Translation", 0x409, 1200
    }



}- Dölj citerad text -

- Visa citerad text -

Yes, there is such a file it is called AssemblyInfo.cs.
I can set the description in this file before I build the exe file.
I need however some way of inject this info into the exe file without
the need to rebuild the exe
 
Back
Top