サウンド ファイルである ZIP ファイルをエクスポートしたいと考えています。
次に、プッシュ通知を使用してこのサウンド ファイルを制御したいと思います。
サウンド ファイルを Xcode に直接ロードすると、機能します。しかし、ファイルが見つからない ZIP ファイルを使用してファイルをエクスポートしますか?
彼がファイルを見つけられないかのように?私は何を間違っていますか?
エラーがここにあると思われます:toDestination:@""
https://github.com/soffes/ssziparchive
- (IBAction)sound_ko:(id)sender {
//File check...
NSBundle *mainBundle = [NSBundle mainBundle];
NSString *myFile = [mainBundle pathForResource: @"KO" ofType: @"zip"];
BOOL fileExists2 = [[NSFileManager defaultManager] fileExistsAtPath:myFile];
if (fileExists2 == NO){
NSLog(@"DOESNT Exist!");
} else {
NSLog(@"DOES Exist!");
}
//Unzip File
if( [SSZipArchive unzipFileAtPath:myFile toDestination:@""] != NO ) {
NSLog(@"Dilip Success");
}else{
NSLog(@"Dilip Error");
}
}