Skip to Content

How to handle Device Back Button in SAP Mobile application (HCPms) Android Platform

Jul 03, 2017 at 06:58 AM


avatar image


I am currently working on SAP mobile app development. i have one shell bar back button which i can handle and i can put any methods over there ..But i want to do same thing in Android device specific Button too...

please help here :)


Virendra Soni

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Murugarajan Shanmugasundaram
Jul 25, 2017 at 05:10 AM
        function onLoad() {
            document.addEventListener("deviceready", onDeviceReady, false);
        function onDeviceReady() {
            document.addEventListener("backbutton", onBackKeyDown, false);
        function onBackKeyDown() {
            alert("You Can Call Me MR.");

// you can use this code to handle the device back button.. 
// call the onLoad() function in your view section. 
// :) Thanks..
10 |10000 characters needed characters left characters exceeded