I am trying to record some audio in my app.
i open the audio recorder with an intent for result. But on result, my data is null.
Am i missing something?
Following is my code
public void onClick(View arg0) {
// TODO Auto-generated method stub
Intent intent =
new Intent(MediaStore.Audio.Media.RECORD_SOUND_ACTION);
startActivityForResult(intent, RQS_RECORDING);
}});
}
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
// TODO Auto-generated method stub
if(requestCode == RQS_RECORDING){
savedUri = data.getData();
Toast.makeText(AndroidIntentAudioRecording.this,
"Saved: " + savedUri.getPath(),
Toast.LENGTH_LONG).show();
}
}
}
thanks in advance
I had buggy issues with this, later I wrote my own recorder app based on this tutorial. It works like a charm for me and recorder is even delivered to client as an add-on in the app I developed for him.