• 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: Simple text question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Simple text question


  • Subject: RE: Simple text question
  • From: "Script2" <email@hidden>
  • Date: Mon, 7 Jul 2008 15:54:58 -0400
  • Importance: Normal

Hi Eric

 

Yes Michelle’s solution worked, but I need to take a step further.

 

I had tried

 

Write text items cnt thru itemcnt of aword to outfile

 

Cnt – position it locates “6000[F]This”

Itemcnt – set itemcnt to number of text items in aword

 

I get error message “can’t get text items 3 to 85 of “ffcco yh56 6000[F]this………………”

 

Ruby

 

-----Original Message-----
From: Eric C Saunders [mailto:email@hidden]
Sent: Monday, July 07, 2008 3:27 PM
To: email@hidden
Cc: Script2
Subject: RE: Simple text question

 


Look at Michelle's answer to your question. Based on her answer, I would write:

        return text items 3 thru 6 of aword

If you continue to us "word of", AppleScript will continue to return "word of".
If you use "text item of" then AppleScript will return "text item of".
In your case, "word of" seems to be an inappropriate term, and Michelle offered the correct term -- text item of.
She REALLY knows what she is doing, and has posted MANY helpful answers on this forum.

Eric

On 07/07/2008 02:08:04 PM Script2 wrote:

> Any Suggestions as to how I can write word 3 thru 6 of aword to a file
> without loosing special characters.
>
> Ruby
>
> -----Original Message-----
> From: applescript-users-bounces+script2=email@hidden
> [mailto:applescript-users-bounces+script2=email@hidden]
> On Behalf Of Michelle Steiner
> Sent: Monday, July 07, 2008 1:48 PM
> To: Applescript Users
> Subject: Re: Simple text question
>
> On Jul 7, 2008, at 10:38 AM, Script2 wrote:
>
> > Thanks Michelle
> >
> > This works.
> >
> > But when I try
> >
> > Set wordcnt to number of words in aword
> > Set newword to word cnt thru wordcnt of aword - it ignore the "[]"  
> > and "()"
> >
> > Cnt is a counter - which word contains "[F]"
>
> That's because, as I said, non alphanumerics are not words, nor part  
> of words.
>
> -- Michelle
>
> --
> "My country, right or wrong: if right, to be kept right; and if wrong,  
> to be set right."
> Senator Carl Schurz of Missouri, 1899
>
>  _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> AppleScript-Users mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
> tern.com
> Archives: http://lists.apple.com/archives/applescript-users
>
> This email sent to email@hidden
>
>
>  _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> AppleScript-Users mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
> > 40meadwestvaco.com
> Archives: http://lists.apple.com/archives/applescript-users
>
> This email sent to email@hidden

This electronic message contains information from MeadWestvaco Corporation or 
subsidiary companies, which may be confidential, privileged or otherwise protected 
from disclosure. The information is intended to be used solely by the recipient(s) 
named. If you are not an intended recipient, be aware that any review, disclosure, 
copying, distribution or use of this transmission or its contents is prohibited. If you 
have received this transmission in error, please notify MeadWestvaco immediately 
at email@hidden.
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

References: 
 >RE: Simple text question (From: Eric C Saunders <email@hidden>)

  • Prev by Date: Re: Simple text question
  • Next by Date: Re: Simple text question
  • Previous by thread: RE: Simple text question
  • Next by thread: Re: Simple text question
  • Index(es):
    • Date
    • Thread