Where does control return to after onPostExecute() method of AsynchTask?
I have an AsynchTask which is called from with in a function in my MainActivity. After the onPostExecute method is executed ,the control doesn't seem to return to the function where I called the AsynchTask.
class AsynchTestClass extends AsynchTask
{
protected int doInBackGround(Integer i){
return i + 10;
}
protected void onPostExecute(Integer r){
doCalculation(r);
}
}
//calling function in Main Activity.
public void showResult()
{
new AsynchTestClass.execute(20);
//Want to continue here, but control doesn't seem to return.
}
The code I write after the new AsynchTestClass.execute(20) doesn't execute. How do I continue after the AysnchTask returns.
.
stackoverflow.comm
No comments:
Post a Comment