• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Removing the carriage return in Quark6
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Removing the carriage return in Quark6


  • Subject: Re: Removing the carriage return in Quark6
  • From: Nan Mossey <email@hidden>
  • Date: Wed, 17 Nov 2004 13:14:47 -0500

See if this helps

repeat with i from 1 to count of paragraphs
 if ((count of characters of paragraph i) ¾ 1) then
delete paragraph i
end if
end repeat

This was written as part of a script for QXP 4.11, but could be tweaked to
work in other programs.


On 11/17/04 12:59 PM, "Steve Foster" <email@hidden> wrote:

> Hi Everyone
>
> I will try to keep this simple. I need to be able to remove unwanted
> carriage returns.
>
> for example, If I have a text box which contains a list such as:
> Name
> Telephone
> Fax
> Mobile
> Email
>
> If I remove one of these such as Fax I will be left with
> Name
> Telephone
>
> Mobile
> Email
>
> When what I want is to remove the return so I have
> Name
> Telephone
> Mobile
> Email
>
>
> To get to this point I have had to do a find and replace on a pre-set
> Quark 6 page as below. I hope this makes sense. In short can anyone help
> me remove unwanted carriage returns?
>
> Thanks
>
> Steve
>
> PS I am using OSX
> PPS My current code is as below but I'm not sure it is too relevant to
> the question. With an else-if I can removed a placeholder but it does
> not remove the carriage return!
>
> Set strName To "Tom"
> Set strPosition to "Captain"
> Set strTelephone to "000 111 222"
> Set strFax to "000 222 333"
> Set strMobile to "000 333 444"
> Set strEmail to "email@hidden,"
> tell application "QuarkXPress"
> activate
> tell document 1
> if (strName is not equal to "") then
> set (every text of every story where it
> is "«Name»") to strName
> --remove(ASCII character 10) --I tried
> this but it does not work!
> else
> set (every text of every story where it
> is "«Name»") to ""
> end if
> if (strPosition is not equal to "") then
> set (every text of every story where it
> is "«Position»") to strPosition
> else
> set (every text of every story where it
> is "«Position»") to ""
> end if
> if (strTelephone is not equal to "") then
> set (every text of every story where it
> is "«Telephone»") to strTelephone
> else
> set (every text of every story where it
> is "«Telephone»") to ""
> end if
> if (strFax is not equal to "") then
> set (every text of every story where it
> is "«Fax»") to strFax
> else
> set (every text of every story where it
> is "«Fax»") to ""
> end if
> if (strMobile is not equal to "") then
> set (every text of every story where it
> is "«Mobile»") to strMobile
> else
> set (every text of every story where it
> is "«Mobile»") to ""
> end if
> if (strEmail is not equal to "") then
> set (every text of every story where it
> is "«Email»") to strEmail
> else
> set (every text of every story where it
> is "«Email»") to ""
> end if
>
> end tell
> end tell

--
Nan Mossey
Times Union Publications Manager
1 News Plaza
Albany NY 12212

518-454-5704


========================================================
This e-mail message is intended only for the personal
use of the recipient(s) named above. If you are not
an intended recipient, you may not review, copy or
distribute this message.

If you have received this communication in error,
please notify the Albany Times Union Help Desk
(email@hidden) immediately by e-mail and
delete the original message.
========================================================
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Removing the carriage return in Quark6 (From: Steve Foster <email@hidden>)

  • Prev by Date: Removing the carriage return in Quark6
  • Next by Date: Re: Removing the carriage return in Quark6
  • Previous by thread: Removing the carriage return in Quark6
  • Next by thread: Re: Removing the carriage return in Quark6
  • Index(es):
    • Date
    • Thread