0 Replies Latest reply on Feb 26, 2008 11:12 AM by (Terry_Ofner)

    resetting page numbers

      I am exporting InDesign pages to xml via xhtml cross-platform export. The only issue I have is that the auto-page numbers do not show up in the xml output. I have been trying to set the content of every text frame whose applied paragraph style is "page" (a style I set on the master pages). Here is my appleScript which does not seem to work:

      tell application "Adobe InDesign CS3"
      tell document 1

      set theStyle to paragraph style "page"
      set DocPages to the document offset of every page

      repeat with i in DocPages
      tell page i
      set pageNum to document offset as string
      set myTextFrames to (every text frame whose applied paragraph style is theStyle)
      repeat with t in myTextFrames
      set contents to pageNum
      tell text 1 of parent story to recompose
      set applied paragraph style of parent story to "page"
      end repeat
      end tell

      end repeat
      end tell

      end tell

      any suggestions would be super. If javascript will work better, let me know that as well.