• 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 leading and railing blanks
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Removing leading and railing blanks


  • Subject: Re: Removing leading and railing blanks
  • From: Michelle Steiner <email@hidden>
  • Date: Tue, 25 Feb 2003 01:32:16 -0700

On Monday, February 24, 2003, at 11:51 PM, Jeffrey Mattox wrote:

What's the most efficient way to remove leading and trailing blanks from a string?

If there is no punctuation in the string:

set foo to " word more and, space "
set text item delimiters to {space}
set bar to (words 1 through end of foo) as text
set text item delimiters to ""
bar


--
"There's some good in the world, Mr. Frodo, and it's worth fighting for."
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.
References: 
 >Removing leading and railing blanks (From: Jeffrey Mattox <email@hidden>)

  • Prev by Date: Re: Scripting Mail:get selection
  • Next by Date: Moving a file and changing its name in X
  • Previous by thread: Re: Removing leading and railing blanks
  • Next by thread: Re: Removing leading and railing blanks
  • Index(es):
    • Date
    • Thread