I have a listview which have checkboxes. For each checkbox (they are about 3), it has a specific AsyncTask for it.
I never know what checkboxes use
you can access ui by this method inside the function doInBackground... :
getActivity().runOnUiThread(new Runnable() {
@Override
public void run() {
if (!dialog.isShowing()) {
dialog.show();
}
dialog.setMessage(getText(R.string.lbl_downloading) + " : " + String.valueOf(mCount) + " / " + String.valueOf(totalItems));
}
});
this is a snipped taken from my code which displays the downnloaded items.