1 Reply Latest reply on Nov 13, 2013 8:12 PM by Sudha K

    Export PowerMath Equations to ASCII

    Sudha K Level 1

      Hi,

       

       

         I want to convert PowerMath equations to ASCII in indesign document. 

       

         app.menuActions.itemByID(471686).invoke();

       

        When I use this code, it shows the dialog "Convert equations to PowerMath ASCII", but the process is not completed.  Don't know how to complete the process.

       

       

       

      How should I  click on 'Document' button to complete the process.  If anyone knows pls help me.

       

      Thanks in advance,

      Sudha K

        • 1. Re: Export PowerMath Equations to ASCII
          Sudha K Level 1

          Hi,

           

          I got some ideas that we can click the document button of Plug-In/Export menu dialog by using applescript.  But its not working for me. Code is,

           

           

          tell application "Adobe InDesign CS6"

              set myString to ""

              set myMainMenu to menu "Main"

              set myTypeMenu to submenu "Plug-Ins" of myMainMenu

              set myFontMenu to submenu "PowerMath" of myTypeMenu

              set myString to name of myFontMenu

           

              repeat with myMenuItem in menu items of myFontMenu

                  set myAssociatedMenuAction to associated menu action of myMenuItem

                  set myActionMenuName to name of myAssociatedMenuAction

                  if myActionMenuName is "Ascii Export" then

                      invoke myAssociatedMenuAction

           

                      activate application "Adobe InDesign CS6"

                      tell application "System Events"

                          tell process "InDesign"

                              delay 1

                             

                              try

                                  keystroke return

           

                              end try

                              delay 6

                              try

                                  keystroke return

           

                              end try

                          

                          end tell

                      end tell

           

                  end if

              end repeat

          end tell

           

           

          Whats wrong in this.  Pls help me.