I'm a stupid guy! Don't know why I tried to use AXUIElementMBS, while I already used RemoteControlMBS! Thanks, Christian, what I was trying to do works well with RemoteControlMBS.Mac(or Win)PressKey.
Jean-Luc Arnaud Le 14/01/2015 18:26, Christian Schmitz a écrit : >> Am 14.01.2015 um 11:26 schrieb Jean-Luc Arnaud <jean-...@cdmultimedia.fr>: >> >> Hello, >> >> Using AXUIElementMBS, is it possible to send a KeyPress event to the >> frontmost application, even if it's not a Xojo one? > Of course with RemoteControlMBS module. > >> I coded that : >> >> dim a as new AXUIElementMBS // get the element >> a.PostKeyboardEvent(0, 53, true ) // Esc down >> a.PostKeyboardEvent(0, 53, false ) // Esc up > what is a? > > >From Apple's AXUIElementPostKeyboardEvent documentation: > You can only pass in the system-wide or application AXUIElementRef. > > so first question is what a.handle is before calling it and what lasterror > property is after calling it. > > > > Greetings > Christian > _______________________________________________ Mbsplugins_monkeybreadsoftware.info mailing list mbsplugins@monkeybreadsoftware.info https://ml01.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info