title: ProgressDialog using AsyncTask producing constructor undefined error
body: <pre><code>public class async extends AsyncTask&lt;String, Integer, String&gt;{
  ProgressDialog prog;
  @Override
  protected void onPreExecute() {
  
      super.onPreExecute();
      prog=new ProgressDialog(async.this);//This is chowing error 
      prog.setProgressStyle(ProgressDialog.STYLE_HORIZONTAL);
      prog.setMax(100);
      prog.show();
  
  }
  
      @Override
      protected String doInBackground(String... params) {
          for (int i = 0; i &lt; 10; i++) {
          publishProgress(5);
              try {
                  Thread.sleep(100);
              } catch (InterruptedException e) {
                  // TODO Auto-generated catch block
                  e.printStackTrace();
              }
          }
          return null;
      }
  
  @Override
  protected void onPostExecute(String result) {
  
      super.onPostExecute(result);
      prog.dismiss();
  }
  @Override
  protected void onProgressUpdate(Integer... values) {
      prog.setProgress(values[0]);
      super.onProgressUpdate(values);
  }
  }
  </code></pre>
  
  <p>The above code is producing the error:</p>
  
  <blockquote>
    <p>the constructor ProgressDialog(AndroidasynctaskActivity.async) is
    undefined</p>
  </blockquote>
  
  <p>Why is this so? Can anyone please help me troubleshoot this?</p>