![](/img/trans.png)
[英]JTable remove row by clicking a cell with a custom DeleteCellEditor from the same JTable
[英]retrieve the row number of a JTable from a cell
我需要知道是否有可能檢索JTable的行號以單擊位於表內部的按鈕。 我需要從特定單元格獲取行數
當您單擊表格中的單元格時,該行將被選中。
要確定選定的行,可以使用:
int row = table.getSelectedRow();
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.