I understand, but that kind of code should be outside of Activity_Create. Activity_Create should be used for setting the layout, views, location, etc. Once the Activity_Create is finished, then do the code to test for this file and call another activity. Move that code out of Activity_Create. This is most likely why you are having the issues.