title: JProgressBar Dialog
body: <p>I'm trying to create a pop up dialog progress bar preferably an Indeterminate but that's not too important.  I have been looking through "Oracle's ProgressBar Tutorials" and Google searching but not such luck in getting it to work.  I'm pasted my code below of my Action Listener and the dialog will not pop up.  Any suggestions? Thanks in advance!</p>
  
  <p>Sorry this is my first post on this site. But how it works is that When I press the create button, it goes out and grab some information from different servers and directories and creates a file for me. That is what the new Project is. Features is a Enumeration I made that are set with the text in the <code>JTextBox</code> when the Create Button. The problem is that this process takes time to process, so I want the a progress bar to show that its processing</p>
  
  <pre><code>private class CreateButton implements ActionListener
  {
      @Override
      public void actionPerformed(ActionEvent arg0) { 
          class Task extends SwingWorker&lt;Void, Void&gt;
          {
              @Override
              protected Void doInBackground()
              {                   
                  //Set Variables
                  for(Feature f : Feature.values())
                  {
                      if(f.getComp() != null)
                      {
                          f.getVariable().setVariable(((JTextField) f.getComp()).getText());
                      }
                  }
  
                  new Project(jobs.getSelectedValue().split("-")[0].trim(), 
                              jobs.getSelectedValue().split("-")[1].trim(),
                              features);
                  return null;
              }
          }
  
          ProgressMonitor pm = new ProgressMonitor(display, "Testing...", "", 0, 100);
          pm.setProgress(0);
          Task task = new Task();
          task.execute();
      }
  
  }   
  </code></pre>