1 Reply Latest reply on Aug 20, 2015 9:07 AM by Scott Dunn (Flux)

    Problem of repeat letters when running event handlers

    JohnHouston Level 1

      When I add an event listener (e.g. beforeDelete to every rectangle see below) using applescript the handler runs OK.


      But when I then type into a text frame in the same document I start getting random repeat characters (e.g. repeeat chaaracters).


      The same applies to other event handlers I've tried (afterActivate and afterSelectionChanged).


      Is this a bug or am I missing something?


      Mac OS X 10.7.4, InDesign CS6.




      tell application "Adobe InDesign CS6"

                tell document 1

                          tell every rectangle

                                    set myPixEventListener to make event listener with properties {event type:"beforeDelete", handler:my doPixhandler, cancelable:true}

                          end tell

                end tell

      end tell


      on doPixhandler()

                tell application "Adobe InDesign CS6"

                          prevent default evt

                end tell

      end doPixhandler