I want my software to switch to fullscreen when the user presses F11 (also within the PDF control). So my program is listening to key events. I wonder why one keypress raises the event twice sometimes.
Code: Select all
_PDFViewer.SetProperty("Notifications.Print.Filter", "All", 0)
_PDFViewer.SetProperty("Notifications.TextEditor.Filter", "All", 0)
_PDFViewer.SetProperty("Notifications.Keyboard.Filter", "All", 0)
Code: Select all
Private Sub _PDFViewer_OnEvent(ByVal sender As Object, ByVal e As AxPDFXCviewAxLib._IPDFXCviewEvents_OnEventEvent) Handles _PDFViewer.OnEvent
If e.name.ToLower.Contains("notifications.keyboard") Then
Dim Code As Integer
_PDFViewer.GetProperty("Notifications.Keyboard.Code", Code, 0)
#If DEBUG Then
Debug.Print("KeyPress: " & Code.ToString)
#End If
KeyPress: 97
KeyPress: 65
Pressing F11 gives me
KeyPress: 122 <- This is the code I am waiting for
BUT pressing Z (German keyboard layout) gives me
KeyPress: 90
KeyPress: 122
So when you type Z within a PDF my program switches to fullscreen. What can I do?