Error saving data to cache directory (iPhone)

前端 未结 1 923
后悔当初
后悔当初 2021-02-05 10:32

I am trying to save images using the following code:

- (void)writeData{

    if(cacheFileName==nil)
        return;
    if(cacheDirectoryPath==nil)
        retur         


        
相关标签:
1条回答
  • 2021-02-05 10:46

    I see that you use some intermediate directory within the Cache Directory, are it/they created? If not try removing them or use

    -[NSFileManager createDirectoryAtPath:withIntermediateDirectories:attributes:error:]
    

    to create them before

    0 讨论(0)
提交回复
热议问题