如何在不同的平台(32位和64位)上显示不同的项目名称. [英] how to show different project name for different platform(32bit and 64bit).

查看:87
本文介绍了如何在不同的平台(32位和64位)上显示不同的项目名称.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在vc ++中有一个项目,对于32位,其名称为 你好 ,在64位中,其名称为 hellox64 .构建后,当我右键单击.exe并看到属性时,两个平台的项目名称都为 hello .现在,我希望32bit的项目名称为 hello ,对于64位,应为 hellox64 .实际上,我已经在项目中添加了资源版本文件,并在其中指定了项目名称,文件在两个平台上都运行.因此我可以在一个项目中添加2个版本文件,还是必须做其他事情.



这是我的资源版本文件--------


Ihave a project in vc++.For 32bit its name hello and in 64bit its name hellox64.But after build when I right click in the .exe and see property the project name comes hello for both platform.Now I want that for 32bit it should be hello and for 64bit it should be hellox64.Actually I have added a resource version file in project and give the project name there and this file is run for both the platform.So can I add 2 version file in one project or I have to do something other thing.



This my resource version file --------


// Microsoft Visual C++ generated resource script.
//
#include "resource1.h"

#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"

/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS

/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources

#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32

#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//

1 TEXTINCLUDE 
BEGIN
    "resource1.h\0"
END

2 TEXTINCLUDE 
BEGIN
    "#include ""afxres.h""\r\n"
    "\0"
END

3 TEXTINCLUDE 
BEGIN
    "\r\n"
    "\0"
END

#endif    // APSTUDIO_INVOKED


/////////////////////////////////////////////////////////////////////////////
//
// Version
//

VS_VERSION_INFO VERSIONINFO
 FILEVERSION 2,0,0,0
 PRODUCTVERSION 2,0,0,0
 FILEFLAGSMASK 0x17L
#ifdef _DEBUG
 FILEFLAGS 0x1L
#else
 FILEFLAGS 0x0L
#endif
 FILEOS 0x4L
 FILETYPE 0x0L
 FILESUBTYPE 0x0L
BEGIN
    BLOCK "StringFileInfo"
    BEGIN
        BLOCK "040904b0"
        BEGIN
			VALUE "ProductName", "Hello"
            VALUE "FileVersion", "2, 0, 0, 0"
            VALUE "LegalCopyright", "\r\n\r\n\r\nCopyright."
            VALUE "ProductVersion", "2,0,0,0"
        END
    END
    BLOCK "VarFileInfo"
    BEGIN
        VALUE "Translation", 0x409, 1200
    END
END

#endif    // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////



#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//


/////////////////////////////////////////////////////////////////////////////
#endif    // not APSTUDIO_INVOKED




因此,如何根据platform.All更改"ProductName",信息将与ProductName相同.




So how can I change "ProductName" according to platform.All the information would remain same expect ProductName.

推荐答案

在项目属性中更改目标名称.花一些时间浏览项目属性中的所有页面(包括宏表),以熟悉可以更改的内容.
Change the target name in your project properties. Spend some time looking through all the pages in the project properties (including the macro tables) to get familiar with the things you can change.


这篇关于如何在不同的平台(32位和64位)上显示不同的项目名称.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆