Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 08-26-2009, 10:38 AM   #2 (permalink)
Dutch
Humbled Student
 
Dutch's Avatar
 
Join Date: Apr 2009
Location: Long Island, NY
Age: 32
Posts: 883
Dutch will become famous soon enough
Send a message via AIM to Dutch
Default

Try Adding into your appDelegate.h

Code:
#import <AudioToolbox/AudioToolbox.h>
The corresponding playSound method

Code:
-(void)playSound: (NSString *)sound withExt:(NSString *)extension{
	NSString *soundPath = [[NSBundle mainBundle] pathForResource:sound ofType:extension];
	SystemSoundID soundID;
	AudioServicesCreateSystemSoundID((CFURLRef) [NSURL fileURLWithPath:soundPath], &soundID);
	AudioServicesPlaySystemSound(soundID);	
	AudioServicesPlaySystemSound(kSystemSoundID_Vibrate); 
}
Dutch is offline   Reply With Quote
 

» Advertisements
» Stats
Members: 175,174
Threads: 93,917
Posts: 402,134
Top Poster: BrianSlick (7,966)
Welcome to our newest member, dremayl49
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 11:52 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.