• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Xml rule processor "//div" cannot find using applescript

Participant ,
Jul 12, 2016 Jul 12, 2016

Copy link to clipboard

Copied

Hi everyone!

     In indesign xml pre processor, cannot find "div" xml element using applescript.

I have try some code but in this case not working. Please give any ideas..

This is my code:

tell application "Adobe InDesign CS6"

    set xpath to {"//div"}

    set myRuleProcessor to make XML rule processor with properties {rule paths:xpath}

    set myRootXMLElement to XML element 1 of document 1

    tell myRuleProcessor

        set myMatchData to start processing rule set initial element myRootXMLElement

        repeat while myMatchData is not equal to nothing

            set myElement to get element of myMatchData

           

            select myElement

            set myMatchData to nothing

        end repeat

    end tell

end tell

Thanks in Advance.

TOPICS
Scripting

Views

271

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Engaged , Jul 12, 2016 Jul 12, 2016

Hi john,

it does not seem to accept  the tag-name "//div". Change it. It worked for me. Hope this can be done in production

Thanks Stefan

Votes

Translate

Translate
Engaged ,
Jul 12, 2016 Jul 12, 2016

Copy link to clipboard

Copied

Hi john,

it does not seem to accept  the tag-name "//div". Change it. It worked for me. Hope this can be done in production

Thanks Stefan

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Jul 12, 2016 Jul 12, 2016

Copy link to clipboard

Copied

LATEST

Thank you very much Stevan...

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines