android - OnActivityResult doesn't receive data -
i started in app activity
var recordintent= new intent(recognizerintent.actionrecognizespeech); startactivityforresult(recordintent, (int)resultactivitycodes.speechresult);
and have stoprecord function
void stoprecord() { setresult(result.ok,recordintent); finishactivity((int)resultactivitycodes.speechresult); }
after execute stoprecord()
function called onactivityresult(int requestcode, result resultcode, intent data)
why data has been null in onactivityresult?
how stop correctly activity variable "data" not null
you need use setresult(int, intent) method in started activity before destroyed. second parameter data parameter of onactivityresult()
method.
Comments
Post a Comment