• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Use of keyPressed to call a form

 
Paul Dudek
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
It is easy enough to change the current Display using commandAction for the soft buttons as this method resides inside the main MIDlet class.
You would simply use something like:

Display d = Display.getDisplay(this);

public void commandAction(Command c, Displayable s) {
if (c == formCommand) {
d.setCurrent(myForm);
}

I was wondering if anyone could tell me how to change display from a Canvas to a Form using keyPressed() which is a method of the Canvas class.
I would rather not have to draw a Form on the Canvas.

Many Thanks,

Paul.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic