views:

15

answers:

2

Is there a way to view all the messages (ie messages created for FormatMessage by the mc.exe message compiler) available within a DLL? It appears they are added as a single resource as type 11. Unfortunately that resource is binary.

+1  A: 

I use Resource Hacker for all things resource-related. These messages show up as a "Message Table" resource that contains all the human-readable strings and their IDs.

Luke
For some reason Resource Hacker showed all the resources except the message table. But the author linked to an open source alternative that DOES show the message table: http://www.wilsonc.demon.co.uk/d10resourceeditor.htm
DougN
A: 

You can use FindResource or FindResourceEx to enum all resources in the DLL. Then you can use MESSAGE_RESOURCE_ENTRY, MESSAGE_RESOURCE_DATA and MESSAGE_RESOURCE_BLOCK to decode the data. See for example http://www.codeproject.com/KB/system/msgdump.aspx for details or serch for other examples searching for the API functions and the sutructures.

Oleg