|
-
January 13th, 2003, 01:10 PM
#1
Updating bitmap resources inside exe or dll
Hi all,
I need to replace bitmap resources in my executable without recompilation, so I'd like to know RT_BITMAP resource type structure.
Any info will be appreciated
Cheers,
Alex
 Please rate this post if you find it helpful 
-
January 13th, 2003, 03:18 PM
#2
get your self an Resource Editor.
i.e: ResHack
Bengi
-
January 13th, 2003, 05:11 PM
#3
Well, the issue is to do it programmatically instead of using resource editors, e.g. VC++'s resource editor does all job just fine...
Cheers,
Alex
 Please rate this post if you find it helpful 
-
January 13th, 2003, 05:31 PM
#4
What Bengi is referring to are Resource Editors that update the resources within an executable, which is what you originally asked for...
Are you instead asking how do do it via API calls, etc.. This would only be necessary if you were going to be performing some type of automatic calculations and then saving the results in the executables resources (which should not be running at that time)...
TheCPUWizard is a registered trademark, all rights reserved. (If this post was helpful, please RATE it!)
2008, 2009,2010
In theory, there is no difference between theory and practice; in practice there is.
* Join the fight, refuse to respond to posts that contain code outside of [code] ... [/code] tags. See here for instructions 
* How NOT to post a question here
* Of course you read this carefully before you posted
* Need homework help? Read this first
-
January 13th, 2003, 05:39 PM
#5
OK, maybe I wasn't formulating my task clear enough.
I actually need to find some description of how RT_BITMAP resource is saved inside the executable. And I should provide such bitmap replacement via API calls for sure. With dialogs, menus, string tables etc. there are no problems, but I did not see any info about bitmaps/icons. So, that's the question...
Cheers,
Alex
 Please rate this post if you find it helpful 
-
January 14th, 2003, 02:37 AM
#6
if you want to Edit your resource programmatically,
Than you will have to lwarn the Pe header from A - Z and backward :-)
the PE header contains all the info that there is on the EXE.
once u have a good grosehold on it, u will be able to write ur own PE editor and from there a resource editor.
a good PE information is by reading :
http://spiff.tripnet.se/~iczelion/files/pe-tuts.zip
Bengi
-
January 14th, 2003, 03:12 AM
#7
Have a look at these APIs:
BeginUpdateResource
EndUpdateResource
UpdateResource
Sorry, but they work on WinNT/2000/XP only...
-
January 14th, 2003, 03:17 AM
#8
Thanks to all for responses.
Exactly UpdateResource function I'm using for all standard resource types except bitmaps and icons. There are 2 parameters
LPVOID lpData, // resource data
DWORD cbData // length of resource data
which structure I need to know in case of RT_BITMAP.
Cheers,
Alex
 Please rate this post if you find it helpful 
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|