Hi All,
First of all i would like to thank you all for your previous valuable suggestions. Currently i am working on JSF application where we used infragistics gridView component. The problem concern is initially when the JSF page is loaded we will display a list of records by specifying the datasource of the ig:gridView.
Now my question is, when the user updates a specific record from the list how to capture only those updated specific records??
Currently i am using gridView.getDataSource(...) method which is returning all the rows in the list which is wrong. I need to get only those records which are updated by the user.
Thanks in Advance
Vijay
Hello Vijay,
If you are using cell editing feature then you can use the cell value change listener or row value chnage listener to get the index of operative row. You can get this information by using the event argument of the listener. Once you have index of the chanded row, you can fetch it from the underlying data model.
Hope it helps you.
Can i have the code please ...
My jsp code looks as below
<
"single"
/>
My java code is
public String rowValueChange(ValueChangeEvent rowEvent) { System. out.println("Row Event 0))))))))))))))))))))"); return ""; } But the control is not coming into my java code.. Do I need to take care of anything else in jsp and java code for using value change listener...?
public
System.
out.println("Row Event 0))))))))))))))))))))");
return ""; } But the control is not coming into my java code.. Do I need to take care of anything else in jsp and java code for using value change listener...?
}
But the control is not coming into my java code..
Do I need to take care of anything else in jsp and java code for using value change listener...?
Hello,
I hope the problem you are facing due to the incorrect event handler signature in your application. You should use following signature:public void rowValueChange(RowValueChangeEvent rowEvent){// Your code goes here}Hope it helps you.
Roshan
Thanks for your reply Roshan
But I have already tested using the same..But my code flow is not hitting the java method...Along with the above code I am also sending my button code. I have two buttons which do two different functionality which actually modify the java list which populates the grid...so I want that changed value of the grid should actually get updated in my java list too in my backing bean.
The most important thing is that "Your RowValueChangeEvent is not triggering" and first thing you should try to find out what its root cause in your code.
You should follow the following step:In JSP:..<ig:gridEditing id="grd_edt1" enableOnMouseClick="single" rowValueChangeListener="#{webgrid_hierarchicalGridPage.rowValueChange}" updateMode="row" />In Java:public void rowValueChange(RowValueChangeEvent rowEvent){System.out.println("Event Triggered");}Also you need to know when the row value change should trigger. If you edit a cell and after editing you move to the next cell of the same row..and you suppose that the row value change should trigger then ofcourse it will not. The cell value change event will trigger as you edit the row and the focus get out from that row.
Hope it helps you. If you still face the issue, please provide your complete code (JSP , and backing bean) by which we could look into this.