ProgressDialog
does not work in an asynchronous task. No errors, just not displayed:
class ProgressDownloader extends AsyncTask<String, String, String> { ProgressDialog PD; Downloader dow = new Downloader(); @Override protected void onPreExecute() { PD.show(getApplicationContext(), null, "Loading Please Wait...", true); } @Override protected String doInBackground(String... arg0) { dow.downloadFile(arg0[0], arg0[1]); return null; } protected void onPostExecute(Boolean result) { PD.dismiss(); } }
ProgressDialog PD = new ProgressDialog();
- Saidolim 4:21 pm