
It seems every time I try to do something with bitmaps, I learn someting that I am not doing right.
I am trying to add some bitmaps to buttons on a form. The buttons are 40X20, and one of them is named btnG1.
The bitmaps are also 40X20, however I have tried various sizes.
The following code should (I think do what I need, however when I run it, nothing happens. No errors, it just does not show the bitmaps.
The code is in the mainform.oc
//**********************************************************
enum
{
G1nor = 7000,
G1sel,
};
Bitmap bitmap;
//Bitmaps for the button icons
@bitmap Bitmap bmppict1 {id = G1nor image16="G1nor.bmp"}
@bitmap Bitmap bmppict2 {id = G1sel image16="G1sel.bmp"}
handler mainForm.onopen()
{
alert("OS version = [" + osvers() + "]");
btnG1.bmpid = G1nor;
btnG1.sbmpid = G1sel;
}
//**********************************************************
The emulator version is 4.1 and the pda version is 5+. I read that for the bitmaps to work in this way the version must be 3.5 or graeter.
Any direction, help or un screwing me up would be appreciated.
Thanks in advance
John Crawford
I am trying to add some bitmaps to buttons on a form. The buttons are 40X20, and one of them is named btnG1.
The bitmaps are also 40X20, however I have tried various sizes.
The following code should (I think do what I need, however when I run it, nothing happens. No errors, it just does not show the bitmaps.
The code is in the mainform.oc
//**********************************************************
enum
{
G1nor = 7000,
G1sel,
};
Bitmap bitmap;
//Bitmaps for the button icons
@bitmap Bitmap bmppict1 {id = G1nor image16="G1nor.bmp"}
@bitmap Bitmap bmppict2 {id = G1sel image16="G1sel.bmp"}
handler mainForm.onopen()
{
alert("OS version = [" + osvers() + "]");
btnG1.bmpid = G1nor;
btnG1.sbmpid = G1sel;
}
//**********************************************************
The emulator version is 4.1 and the pda version is 5+. I read that for the bitmaps to work in this way the version must be 3.5 or graeter.
Any direction, help or un screwing me up would be appreciated.
Thanks in advance
John Crawford