Re: Detecting the minus sign in a string
Re: Detecting the minus sign in a string
- Subject: Re: Detecting the minus sign in a string
- From: Luther Fuller <email@hidden>
- Date: Wed, 23 Jun 2010 12:41:02 -0500
On Jun 23, 2010, at 12:15 PM, Alex Zavatone wrote: I just found out that if you have a string with a minus sign in it, that the minus sign can not be a word.
The string, "This is my - string"
simply ignores the minus sign as a word. Any ideas on how to detect the minus sign? Offset maybe?
On the other hand, there's ...
set x to "This is my - string" set AppleScript's text item delimiters to {space} text items of x --> {"This", "is", "my", "-", "string"}
But, to get this to work correctly, you will need to set TIDs to a list of YOUR word delimiters. And, the result will contain items which are the null string.
|
_______________________________________________
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