1 Reply Latest reply: Jun 11, 2012 10:36 PM by EJP RSS

    ActionListener Write to File

    943008
      Pretty nooby question I guess. Problem is, I have this code:
      private class ButtonHandler implements ActionListener
      {
      public void actionPerformed (ActionEvent event)
      {           
      if (event.getSource () == search)
      {
      query = searchfield.getText();

      }
      }
      }
      I would like to write Query to a file. When I add the "throws IOException" line to the end of the method, it gives me an error. How do I make this work?
      Quick response is appreciated as this assignment is due in two days :(

      - Tj

      Edited by: 940005 on Jun 11, 2012 7:39 PM