Top "Nsdocumentdirectory" questions

An iOS application concept to let applications access the file system from their sandboxed environment.

What is the documents directory (NSDocumentDirectory)?

Can someone explain to me what the documents directory is on an iOS app and when to use it? Here …

ios nsdocumentdirectory
How to find NSDocumentDirectory in Swift?

I'm trying to get path to Documents folder with code: var documentsPath = NSSearchPathForDirectoriesInDomains(NSSearchPathDirectory:0,NSSearchPathDomainMask:0,true) but Xcode gives error: …

ios swift nsdocumentdirectory
Delete specified file from document directory

I want to delete an image from my app document directory. Code I have written to delete image is: -(…

ios objective-c xcode nsdocumentdirectory
Save file in document directory in swift 3?

I am saving files in a document directory in swift 3 with this code: fileManager = FileManager.default // let documentDirectory = fileManager?.urls(…

ios swift nsfilemanager nsdocumentdirectory
how to load image from local path ios swift (by path)

In my app I am storing an image in local storage and I am saving the path of that image …

ios swift image nsdocumentdirectory
How to create directory using Swift code (NSFileManager)

I'm having some trouble with converting Objective-C code to create a directory for Swift. Objective-C: NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, …

ios objective-c swift nsfilemanager nsdocumentdirectory
Delete files from directory inside Document directory?

I have created a Temp directory to store some files: //MARK: -create save delete from directory func createTempDirectoryToStoreFile(){ var error: …

ios swift nsfilemanager nsdocumentdirectory
Save Data to .plist File in Swift

I am trying to save data to a plist file in swift, but the data isn't showing up as it …

ios swift plist nsdocumentdirectory
Is there a safer way to create a directory if it does not exist?

I've found this way of creating a directory if it does not exist. But it looks a bit wonky and …

ios objective-c filesystems nsfilemanager nsdocumentdirectory
How to save file in the documents folder?

I am trying to save data in the documents folder on iPhone 5.1 simulator. NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *…

iphone nsfilemanager nsdocumentdirectory