Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <ul> <li><p>create <a href="http://docs.oracle.com/javase/tutorial/uiswing/components/frame.html" rel="nofollow noreferrer">JFrame</a> with <a href="http://docs.oracle.com/javase/tutorial/uiswing/components/table.html" rel="nofollow noreferrer">JTable</a> (in <a href="http://docs.oracle.com/javase/tutorial/uiswing/components/scrollpane.html" rel="nofollow noreferrer">JScrollPane</a>)</p></li> <li><p>add <a href="https://stackoverflow.com/questions/7423533/jtable-with-jpopupmenu">JPopup with JMenuItems</a> to the <code>JTable</code></p></li> <li><p>override <a href="http://docs.oracle.com/javase/tutorial/uiswing/components/table.html#selection" rel="nofollow noreferrer">ListSelectionListener.SINGLE...</a> to avoiding multiply selections</p></li> <li><p>create <a href="http://docs.oracle.com/javase/tutorial/uiswing/components/dialog.html" rel="nofollow noreferrer">JDialog</a> with <a href="http://docs.oracle.com/javase/tutorial/uiswing/components/text.html" rel="nofollow noreferrer">JTextComponents</a></p></li> <li><p>create <code>JDialog</code> only once time, reuse that for another event from <code>JPopup</code>,</p></li> <li><p>override <a href="http://docs.oracle.com/javase/7/docs/api/javax/swing/JDialog.html#setDefaultCloseOperation%28int%29" rel="nofollow noreferrer">JDialog#setDefaultCloseOperation</a> to HIDE_ON_CLOSE, then you'll play only with <code>setVisible(true/false)</code></p></li> <li><p>get data from selected row and fill required <code>JTextComponents</code> in the <code>JDialog</code>, then call <code>JDialog#setVisible(true)</code> wrapped in <code>invokeLater()</code></p></li> <li><p>put there <code>JButtons</code> (cancel and save) with <code>JDBC</code> statement <code>UPDATE ....</code>, put there <code>boolean</code> variable that representing success from JDBC,</p></li> <li><p>on success to refresh <code>XxxTableModel</code>, then to hide <code>JDialog</code></p></li> <li><p>all updates (<code>JTable</code>, <code>XxxTableModel</code>)to the <a href="http://docs.oracle.com/javase/tutorial/uiswing/concurrency/index.html" rel="nofollow noreferrer">Swing GUI must be done on EDT</a> </p></li> </ul>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload