Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/iphone/41.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Iphone 如何从曲目列表中更改通知的声音?_Iphone_Uitableview_Nsfilemanager_Uilocalnotification - Fatal编程技术网

Iphone 如何从曲目列表中更改通知的声音?

Iphone 如何从曲目列表中更改通知的声音?,iphone,uitableview,nsfilemanager,uilocalnotification,Iphone,Uitableview,Nsfilemanager,Uilocalnotification,我正在制作一个应用程序,其中有一个设置窗口,如图所示。当我点击铃声,然后打开一个铃声列表,我使用此代码通过itunes文件共享 - (void)loadSongsFromDocuments { [listofsongs removeAllObjects]; if(listofsongs==nil) listofsongs=[[NSMutableArray alloc] init]; NSFileManager *fileManager = [NSFileManager default

我正在制作一个应用程序,其中有一个设置窗口,如图所示。当我点击铃声,然后打开一个铃声列表,我使用此代码通过itunes文件共享

- (void)loadSongsFromDocuments {

[listofsongs removeAllObjects];
if(listofsongs==nil)
    listofsongs=[[NSMutableArray alloc] init];

NSFileManager *fileManager = [NSFileManager defaultManager];

NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);

NSString *documents = [paths objectAtIndex:0];

NSString *fullExtension = [NSString stringWithFormat:@".wav"];


for (NSString *fileName in [fileManager contentsOfDirectoryAtPath:documents error:nil ] ) {



    if ([fileName rangeOfString:fullExtension].location != NSNotFound) {


        [listofsongs addObject:fileName];

    }

}


NSLog(@"Songs :%@",listofsongs); 
}

现在我希望,当我选择表视图的任何一行时,就会为本地通知的声音设置音调。我该怎么做


感谢您的帮助…

嘿,如果您拍摄屏幕截图,请按cmd+shift+4,然后点击,它将允许您仅从一个屏幕拍摄屏幕截图。e、 g.没有桌面的单独模拟器;