Link to your activity in onCreate with
//onCreate final Activity activity = this;
Then you can use this in your onCompleted callback
activity.finish();
You may need to make Activity activity global.
EDIT 2/26/2014:
Note that calling finish() from a static method is probably bad practice. You specify a specific instance of an Activity with its own life cycle, which should shut itself off from the static method, something without any life cycle or state. Ideally, you would call finish() from something linked to an Activity .
bclymer
source share