Hi Everybody!
I wonder where to place the AsyncTask in the Application? Can I place it in onCreate Method of my Main Activity?
Can anybody please tell me where I can place the Asynctask method in the Application?
Thanks, david
Hi Everybody!
I wonder where to place the AsyncTask in the Application? Can I place it in onCreate Method of my Main Activity?
Can anybody please tell me where I can place the Asynctask method in the Application?
Thanks, david
Look here for a good explanation of how to use AsyncTask
: http://developer.android.com/resources/articles/painless-threading.html
It is most convenient to place the AsyncTask
as a private class
(i.e. an inner class) inside the Activity
where you need to use it.