Sub Activity_KeyPress (KeyCode As Int) As Boolean
If KeyCode = KeyCodes.KEYCODE_BACK and disableback = true Then
Select Msgbox2 ("Keypad lock back", "", "", "", "Close", Null)
Case DialogResponse.NEGATIVE
Return True
Case DialogResponse.CANCEL
Return True
Case DialogResponse.POSITIVE
Return True
end Select
end If
If KeyCode = KeyCodes.KEYCODE_HOME and disablehome = true Then
Select Msgbox2 ("Keypad lock home", "", "", "", "Close", Null)
Case DialogResponse.NEGATIVE
Return True
Case DialogResponse.CANCEL
Return True
Case DialogResponse.POSITIVE
Return True
end Select
end If
end Sub