Search for a character
Search for a character
- Subject: Search for a character
- From: "Timothy K. Wilkinson" <email@hidden>
- Date: Mon, 19 Sep 2005 11:00:52 -0400
I'm having a syntax problem with parsing a text string.
I've parsed a line of text into individual words in a variable. The word I
want is the only one that contains a "%". However I can't seem to find the
right syntax to parse it out.
Basically I just need a line that says "give me every word in this line that
contains a %".
I'm running 10.4.2 on all of the machines this script would run on.
The part of the script that is affected is this:
do shell script "df -h /"
set theSize to the result as text
set oldDelims to AppleScript's text item delimiters
set AppleScript's text item delimiters to return
try
set theLine to text item 2 of theSize
set AppleScript's text item delimiters to space
--Here's where I need to parse out the "%" sign
set theCap to every text item of theLine that contains "%" as text
Anyone know the syntax I would need?
Thanks!
Tim Wilkinson
ITC-ACHS
University of Virginia
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:
This email sent to email@hidden