NO

Author Topic: Resource editor bitmap and icon resource  (Read 4218 times)

Frank

  • Guest
Resource editor bitmap and icon resource
« on: August 10, 2012, 08:25:11 AM »
Resource-Editor: Is it possible to set a bitmap- or icon resource in a dialog with a character-string? The style-optinon with an numeric value (e.g. #8000) is possible, but not with a character (e.g. "Icon_New" .or. "Bmp_New").

CommonTater

  • Guest
Re: Resource editor bitmap and icon resource
« Reply #1 on: August 10, 2012, 02:37:26 PM »
Yep, I do it all the time.  Bitmaps, Icons, Dialogs, etc. 

Download any of my AddIns and you'll see how it's done in the source code...

For example: http://forum.pellesc.de/index.php?topic=4481.msg16774#msg16774

To do this with, for example a dialog...
 
1) Go into your resources editor
2) Right click and select new -> dialog
3) Now right click the new dialog and select properties
4) Give it a name such as "MYDIALOG" in quotes.
5) Click OK...
6) Double click to edit your new dialog.
 
You can also close the graphic editor and right click on your resource file in the project panel and select "open as text" and do it manually. You will find a line something like...
 
#4000 DIALOGEX DISCARDABLE 6, 18, 261, 172
 
Simply re-edit it to...
 
SETUP DIALOGEX DISCARDABLE 6, 18, 261, 172
 
But... and this is the trick...
You may also have to edit the resource.h file POIDE spits out to eliminate conflicts with your renamed resources.  (Personally I just delete it.)
 
 
« Last Edit: August 10, 2012, 02:52:05 PM by CommonTater »

Frank

  • Guest
Re: Resource editor bitmap and icon resource
« Reply #2 on: August 11, 2012, 02:02:13 PM »
But Thank you for your reply. But that's not what I mean. When I insert a bitmap-style or an icon-style within a dialog, so only bitmaps and icon with numerical values are displayed in the properties-selection.

CommonTater

  • Guest
Re: Resource editor bitmap and icon resource
« Reply #3 on: August 11, 2012, 02:39:40 PM »
But Thank you for your reply. But that's not what I mean. When I insert a bitmap-style or an icon-style within a dialog, so only bitmaps and icon with numerical values are displayed in the properties-selection.

OOPs my bad....  If you mean a picture control, yes, that has to be numeric, selected from the dropdown list in the properties panel. 
« Last Edit: August 11, 2012, 02:41:38 PM by CommonTater »