FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour exe property
Posts: 434
Joined: Wed Jun 06, 2007 02:58 PM
exe property
Posted: Wed Jul 06, 2022 02:28 PM
hi,
this is exe property.


is there any way to insert these property when make an exe ?
description
version
product name
copyright

thank you.
FiveWin for xHarbour 24.02 - Feb. 2024 - Embarcadero C++ 7.60 for Win32 Copyright (c) 1993-2023

FWH 64 for Harbour 19.06 (MSVC++) Jun. 2019 - Harbour 3.2.0dev (r1904111533)

Visual Studio 2019 - Pelles C V.8.00.60 (Win64)
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: exe property
Posted: Wed Jul 06, 2022 03:02 PM
Dear Damiano,

You have to add this section into your RC file:
Code (fw): Select all Collapse
VS_VERSION_INFO VERSIONINFO
 FILEVERSION 1,0,0,1
 PRODUCTVERSION 1,0,0,1
 FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
 FILEFLAGS 0x1L
#else
 FILEFLAGS 0x0L
#endif
 FILEOS 0x40004L
 FILETYPE 0x1L
 FILESUBTYPE 0x0L
BEGIN
    BLOCK "StringFileInfo"
    BEGIN
        BLOCK "0c0a04b0"
        BEGIN
            VALUE "CompanyName", "FiveTech Software SL"
            VALUE "FileDescription", "FWH app test"
            VALUE "FileVersion", "1.0.0.1"
            VALUE "InternalName", "WindowsP.exe"
            VALUE "LegalCopyright", "Copyright (C) FIveTech Software SL 2022"
            VALUE "OriginalFilename", "WindowsP.exe"
            VALUE "ProductName", "TODO: <Product name>"
            VALUE "ProductVersion", "1.0.0.1"
        END
    END
    BLOCK "VarFileInfo"
    BEGIN
        VALUE "Translation", 0xc0a, 1200
    END
END


The simplest way to do it is to open your RC file using Visual Studio Community 2022, then you add a "version" component and easily edit it from Visual Studio Community
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 3022
Joined: Fri Oct 07, 2005 01:45 PM
Re: exe property
Posted: Wed Jul 06, 2022 06:17 PM

Thank you. This is nice.

For other languages, check the Translation codes. English is 0x09.

Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM
Re: exe property
Posted: Thu Jul 07, 2022 12:54 PM
Antonio

Been using this Version.Rc file .. lots of similarities .. but I have to use Notepad to edit but it still serves the purpose

Code (fw): Select all Collapse
// Generated by ResEdit 1.6.6
// Copyright (C) 2006-2015
// <!-- m --><a class="postlink" href="http://www.resedit.net">http://www.resedit.net</a><!-- m -->

#include <windows.h>
#include <commctrl.h>

//
// Version Information resources
//
LANGUAGE 0, SUBLANG_NEUTRAL
1 VERSIONINFO
    FILEVERSION     12,25,0,0
    PRODUCTVERSION  12,25,0,0
    FILEOS          VOS__WINDOWS32
    FILETYPE        VFT_UNKNOWN
    FILESUBTYPE     VFT2_UNKNOWN
    FILEFLAGSMASK   0
    FILEFLAGS       0
{
    BLOCK "StringFileInfo"
    {
        BLOCK "04090025"
        {
            VALUE "CompanyName", "CCI by Richard Lipkin"
            VALUE "FileDescription", "Leave-Travel Info"
            VALUE "FileVersion", "12.25 Prod"
            VALUE "LegalCopyright", "CCI - SA Software"
        }
    }
    BLOCK "VarFileInfo"
    {
        VALUE "Translation", 0x0409, 0x0025
    }
}


Rick Lipkin
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM
Re: exe property
Posted: Thu Jul 07, 2022 12:54 PM
Antonio

Been using this Version.Rc file .. lots of similarities .. but I have to use Notepad to edit but it still serves the purpose

Code (fw): Select all Collapse
// Generated by ResEdit 1.6.6
// Copyright (C) 2006-2015
// <!-- m --><a class="postlink" href="http://www.resedit.net">http://www.resedit.net</a><!-- m -->

#include <windows.h>
#include <commctrl.h>

//
// Version Information resources
//
LANGUAGE 0, SUBLANG_NEUTRAL
1 VERSIONINFO
    FILEVERSION     12,25,0,0
    PRODUCTVERSION  12,25,0,0
    FILEOS          VOS__WINDOWS32
    FILETYPE        VFT_UNKNOWN
    FILESUBTYPE     VFT2_UNKNOWN
    FILEFLAGSMASK   0
    FILEFLAGS       0
{
    BLOCK "StringFileInfo"
    {
        BLOCK "04090025"
        {
            VALUE "CompanyName", "CCI by Richard Lipkin"
            VALUE "FileDescription", "Leave-Travel Info"
            VALUE "FileVersion", "12.25 Prod"
            VALUE "LegalCopyright", "CCI - SA Software"
        }
    }
    BLOCK "VarFileInfo"
    {
        VALUE "Translation", 0x0409, 0x0025
    }
}


Rick Lipkin
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: exe property
Posted: Thu Jul 07, 2022 03:48 PM

Dear Rick,

many thanks for sharing it :-)

regards, saludos

Antonio Linares
www.fivetechsoft.com

Continue the discussion