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

Web and WebWorks Development

Reply
Developer
confinedspace
Posts: 40
Registered: ‎04-16-2010
My Device: na
My Carrier: na
Accepted Solution

Disable/Capture the Escape (Back) Button?

Hi,

 

I'm developing an app that only has two pages; a login page and then the main page. The main page then displays various information by manipulating the DOM. Each 'screen' on the main page can link to other 'screens' (by showing and hiding parts of the DOM).

 

Is there anyway to disable the Escpae Key so when a user clicks it they're not force back to the login page? Or even better, can I capture the event and fire a function to display the previous 'screen'?

 

Regards.

Please use plain text.
BlackBerry Development Advisor
tneil
Posts: 3,708
Registered: ‎10-16-2008
My Device: Z10
My Carrier: Rogers

Re: Disable/Capture the Escape (Back) Button?

An example of trapping the back button can be found here:

http://www.blackberry.com/developers/docs/widgetapi/blackberry.system.event.html

 

You can then perform any functionality you desire :smileyhappy:

Tim Neil
Director, Application Platform & Tools Product Management
Follow me on Twitter
Please use plain text.
Developer
confinedspace
Posts: 40
Registered: ‎04-16-2010
My Device: na
My Carrier: na

Re: Disable/Capture the Escape (Back) Button?

Excellent - thanks Tim!

Please use plain text.