x404.co.uk http://www.x404.co.uk/forum/ |
|
Snow Leopard AppleScript bug? http://www.x404.co.uk/forum/viewtopic.php?f=4&t=2658 |
Page 1 of 1 |
Author: | paulzolo [ Mon Sep 07, 2009 5:03 pm ] | |||||||||
Post subject: | Snow Leopard AppleScript bug? | |||||||||
I have some scripts here, and upt to (and including Leopard), they work fine. In snow Leopard, they fail. This is the kind of code that is causing an error:
Yes, the file planet.jpg is on my desktop. I’ve tried it on a Leopard Mac here, and it works. In Snow leopard, it gives an error. Is this something anyone else knows about and has managed to overcome? |
Author: | Fogmeister [ Mon Sep 07, 2009 5:18 pm ] |
Post subject: | Re: Snow Leopard AppleScript bug? |
What error does it give? |
Author: | paulzolo [ Mon Sep 07, 2009 5:21 pm ] | |||||||||
Post subject: | Re: Snow Leopard AppleScript bug? | |||||||||
Sorry. The error is:
|
Author: | big_D [ Mon Sep 07, 2009 7:06 pm ] |
Post subject: | Re: Snow Leopard AppleScript bug? |
On my machine, it got rid of "drivename:Users:", it started with the username. |
Author: | paulzolo [ Mon Sep 07, 2009 7:27 pm ] | |||||||||
Post subject: | Re: Snow Leopard AppleScript bug? | |||||||||
You get the same error with this AppleScript:
It takes a file you have chosen, turns it into a string, and then tries to turn it back to a file reference. This way, you get a reference to a real file to work with. |
Author: | KindaWobbly [ Mon Sep 07, 2009 11:51 pm ] | |||||||||
Post subject: | Re: Snow Leopard AppleScript bug? | |||||||||
Using your code in Snow Leopard gives me the same error you are getting. Assuming there's a reason why you want it to return a file reference rather than an alias, you can get the same result in 10.6 with something like this:
|
Author: | paulzolo [ Tue Sep 08, 2009 8:43 am ] |
Post subject: | Re: Snow Leopard AppleScript bug? |
HI, What I am doing is fixing a Freeway Action. The Action takes a file reference from Freeway, drops it in some AppleScript and runs it. The file reference I get from Freeway is not a POSIX file - it’s a colon separated path. Anyho, the good news is that using as alias instead of as file specification (Which I have just learned was deprecated a while back) seems to fix the problem. Thanks all. |
Author: | Nick [ Tue Sep 08, 2009 11:05 am ] |
Post subject: | Re: Snow Leopard AppleScript bug? |
Ah - boom boom pow! Glad to hear it's fixed. ![]() |
Author: | paulzolo [ Tue Sep 08, 2009 11:17 am ] | |||||||||
Post subject: | Re: Snow Leopard AppleScript bug? | |||||||||
Just need to test pn the other half’s iMac - which is PPC so is running Leopard. If it}s OK on that, I can get an update out. I’d hate to have to start writing Snow Leopard exceptions into the code.... ![]() |
Page 1 of 1 | All times are UTC |
Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |