If I have a reference to Context
, is it possible to finish the current activity?
I don\'t have the reference to current activity.
In my Case following worked,
I need to finish my activity in a AsyncTask onPostExcute().
Where my AsyncTask class is separate public class , which has a constructor with param of Context.
((Activity)(mContext)).finish();
Only the above worked for me... Anyway I got this idea from @2red13 and @lucy answers... Thanks to all...