Reputation: 192
I have created an application. In that, I have to list of audio files and "Set as ringtone" option there. I don't know how to set audio file as ringtone.
Upvotes: 1
Views: 1254
Reputation: 416
You cannot. Apple doesn't release an API to export/write ringtones to the operating system. But u can make ur audio as ringtone through itunes
Use iTunes file sharing in your app and copy the ringtone file to the app's documents directory.
Set "Application supports iTunes file sharing" to YES in your info.plist
Upvotes: 2
Reputation: 628
It is not possible in iOS.There is no API for setting ringtone. Apple does this for security and safety reasons But u can make ur audio as ringtone through itunes
Enable "itunes file sharing" in info plist
This will help in that case How to add a ringtone from an application to ringtones of iphone?
Upvotes: 1