title: java pass data to JTable's row upon button click
body: <p>I'm doing a java app which has to pass an initialized array of string to display as a row to a JTable.</p>
  
  <p>This is what I tried:</p>
  
  <pre><code>      Object[] _row1;
  
        public PrintMeNow() {
              table = new JTable();
      table.setBounds(16, 203, 362, 16);
      table.setShowHorizontalLines(true);
      table.setShowVerticalLines(true);
      table.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
      table.setModel(new DefaultTableModel(
          new Object[][] {
                  _row1, {2,2,2}, {3,3,3}, {4,4,4}
          },
          new String[] {
              "QTY", "Item Code", "Amount"
          }
      ));
  
       }
  
    btnStart.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent arg0) {
             _row1 = new Object[]{"DN Korina", "DN Madrid", "DN Romania"};
        }
    });
  </code></pre>
  
  <p>But when I pressed the start button, it's not filling the row. What am I doing wrong in here? Help is much appreciated. Thanks.</p>