How can I convert Borland buttons in rc-files to ButtonBMP

Post Reply
User avatar
Otto
Posts: 4470
Joined: Fri Oct 07, 2005 7:07 pm
Contact:

How can I convert Borland buttons in rc-files to ButtonBMP

Post by Otto »

CONTROL "Schalter", 1, "BorBtn", 1 | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 125, 82, 32, 20


How can I convert Borland buttons in rc-files to ButtonBMP equivalent to if it would have been designed from source like for example:

@ 100, 200 BUTTONBMP oBtnBmp OF oDlg ACTION msginfo(1) ;
BITMAP ".\bitmaps\garrow.bmp" PROMPT "Test" TEXTRIGHT SIZE 80, 25 PIXEL;
MESSAGE "From source code"
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Otto,

Save the related bitmap as an external BMP file and then replace "BorBtn" with "Button" in the resource file
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Otto
Posts: 4470
Joined: Fri Oct 07, 2005 7:07 pm
Contact:

Post by Otto »

Thank you Antonio,
what I don’t know is how tell the control which bitmap to use.

CONTROL "Schalter", 1, "Button", 1 | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 125, 82, 32, 20

Regards,
Otto
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Otto,

> how tell the control which bitmap to use

You specify it from the PRG, not from the RC

Please review samples\TestBuBm.prg
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Otto
Posts: 4470
Joined: Fri Oct 07, 2005 7:07 pm
Contact:

Post by Otto »

Thank you.
If you have some extratime have a look at: www.fwcodesnips.com
Post Reply