I want to know the type of the mobile keypad programmatically. Is there any way to track this. If yes, Please guide me to get this issue ?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Haven’t tried this, so may not work, but try and see.
According to this link, J2ME handsets with QWERTY keyboards “almost always return their corresponding ASCII/UTF8 value [as
keyCodeparameter when the framework callsCanvas.keyPressed()]”. So try calling something likeCanvas.getKeyName(65)(i.e. the letter ‘A’).If it throws
IllegalArgumentExceptionyou will know that 65 is not a validkeyCodefor that device, therefore it’s not a QWERTY handset.Let me know if it works!