Hi,
Am trying to detect keypresses on a Tableview on Mac OS X.
The above code works fine on Windows, but doesn't work on a Mac.
How does one trap keypresses on Mac?
Can anyone help out here please.
Thanks.
Am trying to detect keypresses on a Tableview on Mac OS X.
B4X:
'### Delete single selected item from tableview ###
Private Sub TableView1_KeyPressed_Event(e As Event)
Dim KE As Reflector
Dim KeyCode As String
KE.Target = e
KeyCode = KE.RunMethod("getCode")
' Log(KeyCode)
If KeyCode = "DELETE" Then
TableView1.Items.RemoveAt(TableView1.SelectedRow)
nTotItemCount = nTotItemCount -1
End If
End Sub
The above code works fine on Windows, but doesn't work on a Mac.
How does one trap keypresses on Mac?
Can anyone help out here please.
Thanks.