Jun 4, 2004 #1 cigno5e5 Programmer Mar 3, 2004 11 IT i must to select jtable rows with the same mechanism of JMenu, when the mouse is over a table row the table row must be selected. can anyone helps me?? thanks at all!
i must to select jtable rows with the same mechanism of JMenu, when the mouse is over a table row the table row must be selected. can anyone helps me?? thanks at all!
Jun 4, 2004 #2 sedj Programmer Aug 6, 2002 5,610 You will need to look at Mouse events and listeners : http://java.sun.com/j2se/1.4.2/docs/api/java/awt/event/MouseEvent.htmlhttp://java.sun.com/j2se/1.4.2/docs/api/java/awt/event/MouseListener.html A tutorial : http://java.sun.com/docs/books/tutorial/uiswing/events/mouselistener.html Upvote 0 Downvote
You will need to look at Mouse events and listeners : http://java.sun.com/j2se/1.4.2/docs/api/java/awt/event/MouseEvent.htmlhttp://java.sun.com/j2se/1.4.2/docs/api/java/awt/event/MouseListener.html A tutorial : http://java.sun.com/docs/books/tutorial/uiswing/events/mouselistener.html
Jun 4, 2004 Thread starter #3 cigno5e5 Programmer Mar 3, 2004 11 IT i know mouselisteners and mouse events, but the problem is to retrieve the table's row index and column index by mouse coordinates! Upvote 0 Downvote
i know mouselisteners and mouse events, but the problem is to retrieve the table's row index and column index by mouse coordinates!
Jun 4, 2004 Thread starter #4 cigno5e5 Programmer Mar 3, 2004 11 IT FOUND! JTable has methods "columnAtPoint" and "rowAtPoint", i did'nt see these!! thanks anyway at all! Upvote 0 Downvote
FOUND! JTable has methods "columnAtPoint" and "rowAtPoint", i did'nt see these!! thanks anyway at all!