• 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
parsing text / get specific item
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

parsing text / get specific item


  • Subject: parsing text / get specific item
  • From: Christian Vinaa <email@hidden>
  • Date: Sun, 6 Mar 2005 20:33:42 +0100

just FYI this is how its possible to find an emailaddress in some text as long as the address is alone on a paragraph


tell application "AppleWorks 6" set theParas to the paragraphs of front document as list set atSign to "@" set emailList to {} repeat with y in theParas set theChars to characters of y as list repeat with x in theChars if x as text is atSign then copy y as text to end of emailList end if end repeat end repeat

	get emailList

	try
		set emailAddress to item 1 of emailList as text
	end try
end tell
--
Christian Vinaa

...... Meanwhile, aunt Martha, having taken a tramp in the woods,
is lying in a ditch at the edge of town .........................
_______________________________________________
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


  • Follow-Ups:
    • Re: parsing text / get specific item
      • From: Michelle Steiner <email@hidden>
  • Prev by Date: scripting print
  • Next by Date: Re: setting default app for document
  • Previous by thread: scripting print
  • Next by thread: Re: parsing text / get specific item
  • Index(es):
    • Date
    • Thread