I am pretty new to Rich UI development so please excuse me for naive questions.
I am currently working on a Grid with multiple records. com.extjs.gxt.ui.client.widget.grid.CheckBoxSelectionModel is added to enable selection of multiple rows/ records.
The row has mutliple text boxes where the user can change the data.
How do we retrieve the current active row, in case checkbox for multiple rows is checked.
I checked the API for CheckBoxSelectionModel but could not find any method that can return the active row. CheckBoxSelectionModel.getLastFocused() will not help as it returns the last row where the check box was clicked.
Any suggestions on how to retrieve the active row where the user is editing the data?
I don't fully understand your question. When multiple rows are checked, don't they all show as "active"? To get the active row you could call getSelectedItems on the selection model, but this would return all that are selected. Can you provide a code sample?
Our grid has multiple text boxes and select lists. The users have to select a particular row (by clicking the check box) and then they make update to the components in the row. We need to know the cell in which the user is making the change. If we use getSelectedItems(), the method returns all the rows which the user has selected. This does not meet our requirements.
Your initial question was about the active row, but you're saying the cell now...is it the row or the cell you need? From what you're describing, it sounds like you may want to use something like GridRowEditing instead of using checkboxes to indicate which row should be edited. With GridRowEditing you would just click the row to edit.