Custom notification sound not playing iOS objective c -


i'm trying localnotification play custom sound cannot work. have declared , double check file type not work. file called alarm clock.caf , it's added file , 29.4 seconds long, fits guidelines. , localnotification code:

-(void) schedulelocalnotificationwithdate:(nsdate *)firedate { uilocalnotification *notification = [[uilocalnotification alloc] init];      notification.firedate  = firedate;     notification.alertbody = @"hello!";     notification.soundname =  @"alarm-clock.caf";     notification.applicationiconbadgenumber = 0;      [[uiapplication sharedapplication] schedulelocalnotification: notification]; 

how play?

thanks

sometimes there glitch stops working if long if it's under limit. try shortening , renaming no spaces or capital letters notifsound. hope works!


Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -