Re: Error: Stack overflow
Re: Error: Stack overflow
- Subject: Re: Error: Stack overflow
- From: Christopher Nebel <email@hidden>
- Date: Wed, 30 Apr 2003 12:05:41 -0700
On Tuesday, April 29, 2003, at 10:34 PM, Jon Pugh wrote:
At 1:33 AM +0100 4/30/03, John Delacour wrote:
set d to "1/1"
set n to "" & (current date) - (get date d)
set fU to "/tmp/" & n & ".txt"
set f to POSIX file fU
--> file "dx:private:tmp:10286845.txt"
open for access f with write permission
set s to "***** hello *****"
write s to f
close access f
read f
--> "***** hello *****"
tell application "Finder"
get f
--> file "dx:private:tmp:10286845.txt"
set creator type of f to "NISX"
--> STACK OVERFLOW
end tell
It comes from using a "POSIX file" reference in the Finder, which
apparently cannot cope and returns error -2706 which AppleScript
mistakes for errOSAStackOverflow or something.
If you move your file reference into the Finder compatible form, it
all works. ...
Your solution is correct, but your explanation is completely wrong. No
event is sent to the Finder; the error comes from AppleScript trying to
handle the request itself and messing up in a peculiar way. This ought
to work better than it does; I've filed a bug.
--Chris Nebel
Apple Development Tools
_______________________________________________
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.