ArrayList list_of_employees = new ArrayList();
@Action
public void reportAllEmployeesClicked(java.awt.event.ActionEvent evt)
{
this.outputText.setText("");
int i=0;
//JOptionPane.showMessageDialog(null,"test Employee list print");
ListIterator list_ir = list_of_employees.listIterator(); //list_of_employees is of
//obj type ArrayList
while(list_ir.hasNext())
{
String o = new String();
o = (String) list_ir.next();
this.outputText.setText(""+o); // this does not work, why? nothing happens
//no errors and no output
i++;
JOptionPane.showMessageDialog(null,o); // this works
}
}
outputText is of JTextArea type nested inside of a scrolling pane. when i set text with normal String variables the output appears as it should. as the loop runs i am able to obtain output through the JOptionPane. All objects stored in the list are String objects. if there is any more info i need to provide to facilitate a more accurate answer, let me know.
Thanks -Will-