The following line:
Hook.GlobalEvents().KeyPress+= this.GlobalHookKeyPress;
does not trigger within a PowerPoint Addin.
However, the following line:
Hook.AppEvents().KeyPress+= this.AppHookKeyPress;
does trigger the event handler.
This is a problem because if I have a group of shapes selected in PowerPoint and then click a key, the default PowerPoint handler triggers prior to the AppEvents() event, causing an audible 'ding' from PowerPoint before my own code executes. I'm hoping that if I can get the GlobalEvent to trigger, then this will allow be handle the key press before PowerPoint and then set e.Handled=true; preventing PowerPoint from making an audible 'bing'.
The following line:
Hook.GlobalEvents().KeyPress+= this.GlobalHookKeyPress;
does not trigger within a PowerPoint Addin. However, the following line:Hook.AppEvents().KeyPress+= this.AppHookKeyPress;
does trigger the event handler.This is a problem because if I have a group of shapes selected in PowerPoint and then click a key, the default PowerPoint handler triggers prior to the AppEvents() event, causing an audible 'ding' from PowerPoint before my own code executes. I'm hoping that if I can get the GlobalEvent to trigger, then this will allow be handle the key press before PowerPoint and then set e.Handled=true; preventing PowerPoint from making an audible 'bing'.