A couple of things to try:
1. Make sure permission is set in your manifest:
uses-permission android:name=android.permission.RECORD_AUDIO/
2. Make sure the source file's permissions are okay
3. Try calling reset() on the MediaRecorder prior to setting the source.
On Fri, Jan 20, 2012 at 11:55 AM, Raneez rane...@gmail.com wrote:
I get the following error while trying to record audio:
E/AndroidRuntime(759): java.lang.RuntimeException: setAudioSource
failed.
E/AndroidRuntime(759): at
android.media.MediaRecorder.setAudioSource(Native Method)).
Please help me out.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en