I’m kinda new to android, i just wanna ask android what is the event after invoking third party application?
for example i have the following code to open the adobe reader to read my file from the sdcard:
File fileToShow = new File(passedFileToShow);
Intent nextActivity = new Intent();
nextActivity.setAction(android.content.Intent.ACTION_VIEW);
nextActivity.setDataAndType(Uri.fromFile(fileToShow), "application/pdf");
nextActivity.putExtra("itemName", itemName );
startActivityForResult(nextActivity, 0);
after opening the adobe reader and i finished reading the file, how do i call the event after i tap the device back button?
onBackPressed doesn’t work,
onActivityResult doesn’t work too..
thanks a lot for any help! 🙂
if you pressed the back button, it’s going to call onRestart (Also it should call onActivityResult with the resutlCode *Activity.RESULT_CANCELED*)
You can see the whole activity lifecyle here