Re: Comparing for case difference
Re: Comparing for case difference
- Subject: Re: Comparing for case difference
- From: Ben Waldie (AppleScript Guru) <email@hidden>
- Date: Wed, 18 Dec 2002 21:07:56 -0500
Laine,
On Wednesday, December 18, 2002, at 02:58 PM, Laine Lee wrote:
>
I have this script that checks for case difference between two
>
strings, but
>
if the strings are very long, this can really eat up time.
>
>
Can you give me something better for comparing long strings for case
>
difference? Thanks.
---> You could try using "considering case"...
set a to "jeremiah"
set b to "jeremiaH"
Checkchange(a, b)
on Checkchange(x_string, y_string)
considering case
set mychanged to x_string = y_string
end considering
if mychanged then
display dialog "Same!" buttons {"OK"} default button 1
else
display dialog "Different!" buttons {"OK"} default button 1
end if
end Checkchange
Thanks,
- Ben
Benjamin S. Waldie
AppleScript Guru
http://www.applescriptguru.com
_______________________________________________
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.