Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to create a button via J2ME

 
kok seong chen
Greenhorn
Posts: 19
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i wonder how can i create a button(not soft button like ok and cancel)
i wanted to create buttons with graphics. Is that possible in J2ME?
 
Michael Yuan
author
Ranch Hand
Posts: 1427
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You have two ways:
1. Draw a button on the Canvas and override appropriate key event handler methods in Canvas class to handle click events.
2. If you are using MIDP v2, you can develop a CustomItem and use it with the rest of the high-level (Form-based) UI.
 
Ben Hui
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if you are using MIDP 2.0, you can create a String ITem of BUTTON type. it looks like a button on Sony Ericsson P900. I have a screenshot here
http://www.benhui.net/feature/sep900_2.html
cheers,
ben
 
kok seong chen
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thks guys
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic