Delete a file: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 750:
</pre>
 
=={{header|FutureBasic}}==
<syntaxhighlight lang="futurebasic">
include "NSLog.incl"
 
CFURLRef url
 
url = fn URLFileURLWithPath( fn StringByExpandingTildeInPath( @"~/Desktop/input.txt" ) )
if (fn FileManagerRemoveItemAtURL( url ) )
NSLog( @"File \"intput.txt\" deleted." )
else
NSLog( @"Unable to delete file \"input.txt\"." )
end if
 
url = fn URLFileURLWithPath( fn StringByExpandingTildeInPath( @"~/Desktop/docs" ) )
if (fn FileManagerRemoveItemAtURL( url ) )
NSLog( @"Directory \"docs\" deleted." )
else
NSLog( @"Unabled to delete directory \"docs\"." )
end if
 
HandleEvents
</syntaxhighlight>
 
=={{header|Gambas}}==
416

edits