I tried this code but didn't work,
-(void)viewWillAppear:(BOOL)animated {
[super viewWillAppear:animated];
NSString *soundPath = [[NSBundle mainBundle] pathForResource:@"paying with coins and bills" ofType:@"wav"];
AudioServicesCreateSystemSoundID(CFBridgingRetain([NSURL fileURLWithPath:soundPath]), &(soundID));
AudioServicesPlaySystemSound (soundID);
}
It will play only when i runs the xcode project.
My requirement is, in my ipad whenever open my app i need to play a sound. Please help me