oc: NSString* soundPath = [[NSBundle mainBundle] pathForResource:@"in" ofType:@"caf"]; NSLog(@"soundPath:%@", soundPath); swift 3.0: let audioFile = Bundle.main.path(forResource: "in.m4a", ofType: nil) print(audioFile) WechatIMG18 1.jpeg