I want to make iPhone vibrate and I found the code
AudioServicesPlaySystemSound(kSystemSoundID_Vibrate);
but Xcode 4.3.2 reports error: undeclared identifier kSystemSoundID_Vibrate
What's the problem?
Try:
AudioServicesPlayAlertSound(kSystemSoundID_Vibrate);
EDIT: Also make sure you import AudioToolbox.framework
#import <AudioToolbox/AudioToolbox.h>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With