开发者

Command-line tool which replaces .manifest file

This will be short: Is there any command line tool to replace .m开发者_JAVA技巧anifest file in application?

// Edit: I mean in resources of EXE.


The command line tool is brcc32.exe which comes with Delphi. Supposing your manifest is in the file named manifest.xml:

1) Create file manifest.rc with the following contents:

1     24     manifest.xml

2) Compile the .rc file with brcc32

3) Add the resulting .res file to your .dpr file:

{$R manifest.res}

Alternatively, instead of steps 2) and 3) just add the .rc file to your .dpr file:

{$R 'manifest.res' 'manifest.rc'}

This will include compiling the resource in the IDE build process so you don't have to invoke brcc32 manually.

Note: Also disable "Enable runtime themes" in Project Options since that would replace your explicit manifest resource. Instead, include the appropriate Common Controls declaration in your own manifest.


I'm unaware of command line tools to do it, though you could knock your own up pretty easy using the resource API's, there's definately calls to do this:

http://msdn.microsoft.com/en-us/library/ms648049(VS.85).aspx


There is a command-line tool to modify resources: ResHacker. http://www.angusj.com/resourcehacker/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜