Write info in .exe

Miscellaneous Forums/General Discussion/Write info in .exe

Hi
I'm looking for a solution to insert version info into the .exe, like version name, description, language, copyright and so on...
Is there something for Blitz3d/Blitzmax? I see that for other languages this is done directly in the main program (setting up some file .res).
Thanks in advance!

Global version:String =version number: 1.21"


Generally your version control software [like Subversion] will be responsible for keeping track of version numbers and making sure you have the correct version in your working copy. You will have to setup keyword substitution, and make sure your string is formatted correctly for it all to work, tho'.

There is a misunderstanding in what I mean.

When you click on properties-menu on an .exe file (at last in XP or NT) you obtain a window with different tabs: General, "VERSION", Compatibility and Summary.
The tab VERSION is not ever present, only in some program (ie: Blitz3d has not version tab, nor BlitzMax, while Nero has it).
I want to know how insert those informations - it there's a way to do in a simple way.
Byez

I think this should do the trick:

http://www.angusj.com/resourcehacker/

but changing the values can result in crash crash crash crash crash... and then not working...

Thank you very much! I've already ResHack, but I dont' think that it can manage these informations...I will try.

I do it using "Imports". It saves having to ResHack every time you compile. If you've got MinGW installed, make a .rc file (using notepad) in the root and paste this into it:

1 VERSIONINFO 
FILEVERSION 1,0,0,0 
PRODUCTVERSION 1,0,0,0 
FILEOS 0x40004
FILETYPE 0x1
{ 
BLOCK "StringFileInfo" 
{ 
 BLOCK "040904b0" 
 { 
  VALUE "Comments", "This is the product description."
  VALUE "CompanyName", "My New Company" 
  VALUE "FileVersion", "1.0.0.0" 
  VALUE "FileDescription", "This is the file description." 
  VALUE "InternalName", "This is the internal name." 
  VALUE "LegalCopyright", "Any info relating to Copyright" 
  VALUE "LegalTrademarks", "" 
  VALUE "OriginalFilename", "MyApp.exe" 
  VALUE "ProductName", "My Application" 
  VALUE "ProductVersion", "1.0.0.0" 
 } 
}
BLOCK "VarFileInfo"
{
  VALUE "Translation", 0x0409, 0
}
}
Change the values to whatever you want, then at the command line, type "C:\MinGW\bin\windres.exe -i C:\stuff.rc -o C:\exeinfo.o". Make sure the paths don't have any spaces in them (that's why I usually store these in the root). Then in BlitzMax, just copy the exeinfo.o file into the same directory, and add:

?win32
Import "exeinfo.o"
?
Then just compile like normal and enjoy....


Hope this helps


Seb

ohhh SEB that is a fantastic idea!!!