title: Can't dismiss ProgressDialog in onPostExecute
body: <p>So, my progress dialog not dismiss in onPostExecute. I'm using fragment. I didn't know where my problem is. I had search and try many solution, but all of that not working</p>
  
  <p>As I said before, I had try many solution but it didn't work. And my progress dialog still show.</p>
  
  <p>This is how I run the AsyncTask</p>
  
  <pre><code>new FetchDataServer().execute();
  </code></pre>
  
  <p>And here is my AsyncTask class code. Tell me where my mistake is.</p>
  
  <pre><code>private class FetchDataServer extends AsyncTask&lt;String,String,String&gt;{
  
          @Override
          protected void onPreExecute() {
              super.onPreExecute();
              pd = true;
              progressDialog.show(getActivity(), "Permintaan diproses", "Loading...");
          }
  
          @Override
          protected String doInBackground(String... strings) {
              getOneWayResult(input_data);
              progressDialog.dismiss();
              return null;
          }
  
          @Override
          protected void onPostExecute(String s) {
              Log.d("HAHA","Executed");
              System.out.println("Masuk post execute");
              if(progressDialog.isShowing() || pd){
                  progressDialog.dismiss();
                  pd = false;
              }
          }
      }
  </code></pre>
  
  <p>I expected it to be dismiss immediately. It really disturbing my job. Currently in hurry to collect it. Thanks for your time.</p>