如何在 cocoa 中移动目录?
每当我使用 NSFileManager 时,都会出现错误。
NSFileManager* fileManager = [NSFileManager defaultManager];
[fileManager moveItemAtPath:[srcpath retain] toPath:[dstpath retain] error:&error];
我最终收到错误:
nameOfDir1 couldn't be moved to nameOfDir2
最佳答案
哦,我必须在要复制到的目录后面输入要复制的目录名称。
关于 cocoa 移动目录,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4902315/