On 14 Apr 2021, at 12:22, Jan Erik Moström wrote:
Basic AppleScript question: How do I move the insertion point to the
end of the current document?
I tried with something like this
tell application "BBEdit"
activate
open file_path
tell front window
select character after endLine
end tell
end tell
or "insertion point" but I'm doing it wrong. Could someone enlighten
me how to do this?
This should work:
tell app "BBEdit"
activate
open file_path
select insertion point after last character of document 1
end tell
(It's best to always target documents, rather than windows; though
that's not the proximate issue here. "document 1" is always the active
document.)
R.
--
Rich Siegel Bare Bones Software, Inc.
<sie...@barebones.com> <https://www.barebones.com/>
Someday I'll look back on all this and laugh... until they sedate me.
--
This is the BBEdit Talk public discussion group. If you have a feature request or need
technical support, please email "supp...@barebones.com" rather than posting here.
Follow @bbedit on Twitter: <https://twitter.com/bbedit>
---
You received this message because you are subscribed to the Google Groups "BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/bbedit/A97D238B-D906-4410-863A-947AABF33280%40barebones.com.