Skip to main content
Inspiring
November 25, 2009
Answered

(AS) Select Paragraph Text without highlighting carriage return

  • November 25, 2009
  • 1 reply
  • 526 views

(AS) Select Paragraph Text without highlighting carriage return character.

I need help with selecting a paragraph located in a story.
The selection should not contain a "hard return" (ASCII number 13")

My current sample is shown below:
-- sample assumes that insertion point is already placed within a specific paragraph...

tell application "Adobe InDesign CS3"
activate   
set theDoc to active document
    tell theDoc
    select paragraph 1 of selection
end tell --theDoc
end tell --app

It seems simple... The above sample will select my chosen paragraph,

but it also selects the carriage return also. How would I go about doing this?

Any advice would be helpful!

Thank you!

This topic has been closed for replies.
Correct answer sstanleyau

Try:

select text from character 1 to character -2 of paragraph 1 of selection

1 reply

sstanleyauCorrect answer
Inspiring
November 25, 2009

Try:

select text from character 1 to character -2 of paragraph 1 of selection

macian2Author
Inspiring
November 25, 2009

Thank You sstanleyau !

Your answer was more than simple! It was complete.