Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Developer
Posts: 115
Registered: ‎10-24-2009
My Device: Not Specified

Re: place an image on a Button

ya i commented it  but i have still error in line

 

 

1)Bitmap.getBitmapResource("help.bmp"); //in ur code Bitmap.getBitmapResource("img/pink_scribble.bmp"); i have chnaged the image and its path

2)Bitmap.getBitmapResource("help1.bmp"); // n ur code Bitmap.getBitmapResource("img/blue_scribble.bmp"); i have chnaged the image and its path

 

Please help me

 

Developer
Posts: 984
Registered: ‎02-10-2009
My Device: Not Specified

Re: place an image on a Button

[ Edited ]

Replace the following code (posted by Blanc)

     private Bitmap on;  
     Bitmap.getBitmapResource("img/pink_scribble.bmp");
     private Bitmap off; 
     Bitmap.getBitmapResource("img/blue_scribble.bmp");

with

 

    private Bitmap on = Bitmap.getBitmapResource("img/pink_scribble.bmp");
    private Bitmap off = Bitmap.getBitmapResource("img/blue_scribble.bmp");

 

Regards

Bikas

 

 

Developer
Posts: 638
Registered: ‎07-02-2009
My Device: Not Specified

Re: place an image on a Button

[ Edited ]

comment those two lines  Bitmap.getBitmapResource("...");

Thanks and Regards,
PraveenGoparaju.
Developer
Posts: 115
Registered: ‎10-24-2009
My Device: Not Specified

Re: place an image on a Button

ya tried both the ways but still the application is not installing(available) on the simulator.but .cod file is created

what might be the problem , please help me 

 

Regards

Divya

Developer
Posts: 984
Registered: ‎02-10-2009
My Device: Not Specified

Re: place an image on a Button

1. Make sure you made your project Active (Projects -> Srt Active Projects..)

2. Also give a look in the 'Downloads' folder, maybe you will get the application there if it is already not in the homescreen.

 

 

Regards

Bikas

New Developer
Posts: 18
Registered: ‎07-17-2009
My Device: Not Specified

Re: place an image on a Button

Thank you.