• 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
underscore and splitting words from string...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

underscore and splitting words from string...


  • Subject: underscore and splitting words from string...
  • From: "charlie" <email@hidden>
  • Date: Wed, 09 Jan 2008 19:19:21 +0000


please explain how to get:

{"item_a", "item_b", "item_c"}

from:

"item_a item_b item_c"

instead of:

{"item", "_", "a", "item", "_", "b", "item", "_", "c"}

which i get when i run:

set listofthree to text of words of "item_a item_b item_c"

i've also tried:

set savedTextItemDelimiters to AppleScript's text item delimiters
set AppleScript's text item delimiters to {" "}
set listofthree to text of words of "itema itemb itemc"
set AppleScript's text item delimiters to savedTextItemDelimiters

... but it didn't help

many thanks for any help you can provide.

- chuck


_______________________________________________ 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
  • Follow-Ups:
    • Re: underscore and splitting words from string...
      • From: Michelle Steiner <email@hidden>
  • Prev by Date: How to get the app in use
  • Next by Date: Leopard breaks Path Item and Photoshop and CS3
  • Previous by thread: Re: How to get the app in use
  • Next by thread: Re: underscore and splitting words from string...
  • Index(es):
    • Date
    • Thread