figorra Member Licensed User Longtime User Aug 8, 2014 #1 Hi all, I want to detect a KeyDown event like public boolean onKeyDown (int keyCode, KeyEvent event), but don't work...... During that time I want do something I test with: Code: Copy Sub Activity_onKeyDown (KeyCode As Int) As Boolean 'Return True to consume the event If KeyCode = KeyCodes.xxxxxxx Then Log("Down") ToastMessageShow("Play LARGOOOOO", False) Return True End If End Sub Any ideas? Is valid too longkeypress........
Hi all, I want to detect a KeyDown event like public boolean onKeyDown (int keyCode, KeyEvent event), but don't work...... During that time I want do something I test with: Code: Copy Sub Activity_onKeyDown (KeyCode As Int) As Boolean 'Return True to consume the event If KeyCode = KeyCodes.xxxxxxx Then Log("Down") ToastMessageShow("Play LARGOOOOO", False) Return True End If End Sub Any ideas? Is valid too longkeypress........
figorra Member Licensed User Longtime User Aug 8, 2014 #2 figorra said: Hi all, I want to detect a KeyDown event like public boolean onKeyDown (int keyCode, KeyEvent event), but don't work...... During that time I want do something I test with: Code: Copy Sub Activity_onKeyDown (KeyCode As Int) As Boolean 'Return True to consume the event If KeyCode = KeyCodes.xxxxxxx Then Log("Down") ToastMessageShow("Play LARGOOOOO", False) Return True End If End Sub Any ideas? Is valid too longkeypress........ Click to expand... EREL Please. Help to me. I search for days in forums, but no solution....... Upvote 0
figorra said: Hi all, I want to detect a KeyDown event like public boolean onKeyDown (int keyCode, KeyEvent event), but don't work...... During that time I want do something I test with: Code: Copy Sub Activity_onKeyDown (KeyCode As Int) As Boolean 'Return True to consume the event If KeyCode = KeyCodes.xxxxxxx Then Log("Down") ToastMessageShow("Play LARGOOOOO", False) Return True End If End Sub Any ideas? Is valid too longkeypress........ Click to expand... EREL Please. Help to me. I search for days in forums, but no solution.......
Erel B4X founder Staff member Licensed User Longtime User Aug 8, 2014 #3 You can see the activity events here: http://www.b4x.com/android/help/views.html#activity You should use KeyPress. Upvote 0
You can see the activity events here: http://www.b4x.com/android/help/views.html#activity You should use KeyPress.