Go Back   The macosxhints Forums > OS X Help Requests > AppleScript



Reply
 
Thread Tools Rate Thread Display Modes
Old 04-15-2012, 10:27 PM   #1
sojourner
Major Leaguer
 
Join Date: Apr 2010
Posts: 371
Satimage osax buggy

Code:
tell application "Finder"
	set textFileName to name of theFile
	set textFileExtension to name extension of theFile
end tell
		
set listTextMatch to find text "qbert [0-9]{3,5}" in textFileName with regex
The above script worked at first, then just stopped. It keeps returning the error "-2763: No result was returned from some part of this expression."

I'm using the Satimage osax (for the find text command). I saw some older information that there used to be problems because the osax wasn't 64-bit. It has supposedly been updated, but it doesn't seem to be working consistently.

Anyone else having similar problems or suggestions?
__________________
see a problem; solve a problem.
sojourner is offline   Reply With Quote
Old 04-21-2012, 08:00 PM   #2
tw
Hall of Famer
 
Join Date: Apr 2007
Posts: 4,262
Your syntax is wrong. Satimage uses the keyword regexp (note the 'p' at the end). change the last line to read:

set listTextMatch to find text "qbert [0-9]{3,5}" in textFileName with regexp

and it will work fine.
__________________
Philosophy is a battle against the bewitchment of our intelligence by means of language. -LW-
tw is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT -5. The time now is 01:44 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.
Site design © IDG Consumer & SMB; individuals retain copyright of their postings
but consent to the possible use of their material in other areas of IDG Consumer & SMB.