Sub Activity_KeyPress (KeyCode As Int)
If KeyCode = KeyCodes.KEYCODE_BACK Then
Msgbox2Async("You hit the BACK button, do you want to close the app?", "", "Yes", "", "No", LoadBitmap (File.DirAssets, "question.png"), False)
Wait For Msgbox_Result (Result As Int)
If Result = DialogResponse.POSITIVE Then
ExitApplication
End If
Else
Return
End If
End Sub