• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Are there a way to put a Form and a TextBox in one display?

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi everyone, i'm a newbie in Java and also in J2ME. I'm practising in J2ME and i want to write an application in which there are a textfield for phone number, and a textbox for message content. But my book only show me how to put a textfield on a form, then display.setCurrent(form) . Please tell me are there a way to put my Form and TextBox together? And i'm a vietnamese, so don't get mad with my English
 
Saloon Keeper
Posts: 27762
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
We get lots worse English than that. But a Form is a container for GUI controls, so the TextBox has to go inside a form. So not only is there a way, you actually have to do it that way. Otherwise it won't work!
 
anh tuan
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you for answering, but i still don't get it. Because Form and TextBox both are extend class of Display, how can i put a TextBox inside a Form. Can you show me some code for example?
 
anh tuan
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And i also have a problem in keyPressed. I'm writing a calculator run on mobile, and when i want to catch the key-up pressed event, i found out there're no keycode for that event. There are KEY_NUM0, KEY_NUM1... but no KEY_UP, KEY_DOWN, KEY_LEFT, KEY_RIGHT and KEY_SELECT (the key at the center). I tried to use the UP, DOWN,... in game action but it didn't work. Thanks for any help, especially if there are code for example.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic