Hi,
I have a main() which starts two threads, one which polls a device and populates a hashtable and the other an event-dispatcher GUI
thread with uses a TableModel to take data from the hashtable and draw a table.
In debug mode an exception is thrown in the java.awt.Container class:
throw new ArrayIndexOutOfBoundsException("No such child: " + n);
at this line
javax.swing.SwingUtilities.invokeLater(new Runnable() {
I reckon I'm not initializing something in the GUI properly but can't think what.
I would be very gateful for any ideas on this.
public static void main(
String[] args) {
WebPortalSimulator x = new WebPortalSimulator();
x.start();
javax.swing.SwingUtilities.invokeLater(new Runnable() {
public void run() {
MainWindow mainWindow = new MainWindow();
}
});
}