Re: underscore and splitting words from string...
Re: underscore and splitting words from string...
- Subject: Re: underscore and splitting words from string...
- From: "charlie" <email@hidden>
- Date: Wed, 09 Jan 2008 19:25:46 +0000
correction in description of problem:
that lower block should have had underscores too, obviously...
set savedTextItemDelimiters to AppleScript's text item delimiters
set AppleScript's text item delimiters to {" "}
set listofthree to text of words of "item_a item_b item_c"
set AppleScript's text item delimiters to savedTextItemDelimiters
the problem remains. i just wanted to fix this typo in the description
of problem.
anyone know how to keep underscores from acting as implicit delimiters?
- chuck
On January 9, 2008, charlie wrote:
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
_______________________________________________
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