Create a reference to the default file manager and pass it the removeItemAtPath:error: message. In the code below, myPath is the path to the file you want to delete. The NULL value can be replaced with an NSError ** to get error info if there's any. If you do that, replace the NULL with &myNSErrorVariableName.
Create a reference to the default file manager and pass it the removeItemAtPath:error: message. In the code below, myPath is the path to the file you want to delete. The NULL value can be replaced with an NSError ** to get error info if there's any. If you do that, replace the NULL with &myNSErrorVariableName.
Myers, thanks for the help. I want to delete a .db file in the Apps Document Directory. Could you please show me in the "removeItemAtPath:" function how to select that exact .db file and path.
I implemented your code, but it doesn't work. I believe that the error is in my project somewhere because the code you shared makes sense and should work. I will let you know when I figure it out.
I'm presuming that you know the name of the file you want to delete .
Thanks again for your time. I figured out what was going on. We are creating another directory in the documents directory, (i.e. = \\documents\images) in which the files that I need to delete are located. I was trying to access the files in the documents directory not the secondary directory. I am trying to figure out how to access the secondary directory. I am new to low level file management and I will read through the documentation, though any help would be nice.