Check that file exists: Difference between revisions
→{{header|FutureBasic}}
No edit summary |
|||
Line 1,434:
CFURLRef url
url = fn URLFileURLWithPath( fn StringByExpandingTildeInPath(@"~/Desktop/
if (fn FileManagerFileExistsAtURL( url ) )
NSLog( @"File
else
NSLog( @"File \"input.txt\" does not exist at this location." )
end if
url = fn URLFileURLWithPath( fn StringByExpandingTildeInPath(@"~/Desktop/docs") )
if (fn FileManagerIsDirectoryAtURL( url ) )
NSLog( @"Directory \"docs\" exists." )
else
NSLog( @"Directory \"docs\" does not exist at this location." )
end if
HandleEvents
</syntaxhighlight>
=={{header|Gambas}}==
|