Previous | Index | Next |
Specialist conversion methods
fileFromURL:
Pass an NSURL, and a file («class furl») will be returned. You will need to coerce the result with "as «class furl»"
+ (NSAppleEventDescriptor *)fileFromURL:(NSURL *)theUrl
theUrl = an NSURL
A file (still needs coercing from NSAppleEventDescriptor)
Version 1.0.0
If possible, use BridgePlus script library’s ASify from command instead.
use scripting additions
use framework "Foundation"
use script "BridgePlus"
load framework
set aURL to Cocoaify (path to desktop)
--> (NSURL) file:///Users/shane/Desktop/
set theResult to current application's SMSForder's fileFromURL:aURL
theResult as «class furl»
--> file "Macintosh HD:Users:shane:Desktop:"