testing testing - 11 months ago 173
iOS Question

Xamarin.iOS: NSTemporaryDirectory()


available for Xamarin.iOS? I can't find something in the Xamarin API. How is it related to described directories here?

Answer Source

You can use the normal GetTempPath method to obtain the file path:

var temp = System.IO.Path.GetTempPath();

Or if you need a NSUrl:

var nsURL = NSFileManager.DefaultManager.GetTemporaryDirectory();

The NSUrl absolute url is the same path, just prefixed with file://