newbie: image as background

J

Jeff

Hey

midp 2.0
J2ME Wireless Toolkit 2.2
JDK 5

My J2ME code uses a form which I want to place 2 textfields and a image. I
want this image to fill the entire screen and be the background for these 2
textfields...

I've tryed using this code, but it only displays the textfields beneath the
image.
txtTestA = new TextField("xxxxxxxxxxxx ", "", 15, TextField.ANY);
txtTestB = new TextField("yyyyyyyyyyyy ", "", 15, TextField.ANY);
try {
Image background = Image.createImage("/jalla.png");
append(background);
}
catch (java.io.IOException e) {
}
append(txtTestA);
append(txtTestB);

But I want the textfields to be placed on the image... (the image works as a
background). So I've been looking for a solution on how to do this. I did
find a post in this newgroup suggesting using a Canvas for this, here I get
lost... I'm not sure how to program a Canvas to create a background image..
I would be happy if someone could post some example code showing how to
create a background image using Canvas on a Form...

Regards

Jeff
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,013
Latest member
KatriceSwa

Latest Threads

Top