Re: QuarkXPress: Script crashes: why?
Re: QuarkXPress: Script crashes: why?
- Subject: Re: QuarkXPress: Script crashes: why?
- From: Hans Haesler <email@hidden>
- Date: Fri, 16 Feb 2001 22:07:11 +0100
On Fri, 16 Feb 2001, Michael Turner wrote:
>
The following snip crashes my Quark:
[snip]
>
What did _I_ do?
Michael,
I did not run your script (I'm not in the need for a crash right now).
But I'd say that you did _not_:
- address the document;
- address the text as 'text 1';
- insert some parentheses to delimit the items.
Then: since the additional text is to be inserted _before the first_ and
_after the last_ character you don't need to set them to anything, just
insert your strings. I don't think that you need to address the current
spread, that's why I left it out.
This works for me:
---
set elementString to "Michael"
set addString to "Turner"
tell document 1 of application "QuarkXPress 4.11"
activate
tell text box "FredTheBox"
copy "<ELEMENT=" & elementString & "a" & ">" & return to before paragraph 1 of story 1
copy addString to after last paragraph
end tell
end tell
---
And, please, do yourself a favor and update to QXP 4.11. And rename
the application by dropping the trade-mark symbol (this would mean
-- at least -- one character less to be mangled by the list server ;-)
Regards,
Hans
---
Hans Haesler | email@hidden