hallo gyus i have a problem
i create a table, and populate its data through the pojo,now this i am select one row and this data will be display in another panel , then i write a class which will
implement ListSelectionListener,i am just showing you the code sample, this is an inner class
class AddaxFMSBodySelectionListener implements ListSelectionListener {
int[] selRows;
Object value;
public void valueChanged(ListSelectionEvent listSelectionEvent) {
boolean adjust = listSelectionEvent.getValueIsAdjusting();
if (!adjust) {
selRows = table.getSelectedRows();
int selections[] = table.getSelectedRows();
int selectedValues[] = table.getSelectedColumns();
// value = table.getValueAt(selRows[0], i);
if (selRows.length > 0) {
for (int i = 0; i < 4; i++) {
// get Table data
TableModel model = table.getModel();
value = model.getValueAt(selRows[0], i);
/*Here i am finding the single row value*/
/**
String name = AddaxFMSDataItem.class.cast(value).getName();
**/
//but when i try to find out only single value of the cell then i will got stuck
System.out.println("Selection : " + value);
}
System.out.println();
}
If any body got any idea then help me.