Ag-grid editable table, one column is a dropdown selection

Hello Experts,

I am looking for an option in ag-grid editable table,Where full row is in edit mode in ag-grid, one column is a dropdown selection and the others are simple text editors.

I am unable to find an option for this requirement.

Thank you in advance for your support.

Hi @Ram_Ch , you can first define your list like below:
dropdownlst = (‘A’, ‘B’, ‘C’)

And then configure the column like below:
gb.configure_column(“Your Col Name”, editable=True, cellEditor=‘agSelectCellEditor’, cellEditorParams={‘values’: dropdownlst })

When you double-click on any cell in that column, the dropdown list should appear and be choosable.

Cheers

4 Likes

Thank you Shawn for the quick response!!

It is nice. But in st.selectbox, when user type, automatically the options that are consistent comes up to list. But in this model explained above user must choose. I have a very long list. Is there any way that I create something similar to st.selectbox?

Hi @Sinakian, there is a search option on the aggrid site, but I haven’t tried that as yet.

Will ping you in case I find a way to do so.

Maybe, someone else can immediately help in the interim?

Cheers

1 Like

How can i change the single selection into multiple selection ??
And once the user select more than one value they are displayed in the cell seperated with comma.

I need to try this out, @leb_dev.

Cheers

dear Shawn, please share the dynamic data. I mean API make call needs to bind for aggrid dropdown while editing option. Actually, static data is working fine. thank you in advance.

Hi @Shawn_Pereira , Is there a way that dropdown on each row can have different options?

No. Ordinarily, I don’t think a dropdown in the same column on each row can have different options. But who knows, there may be someone else on this forum who can be more inventive with JS and accomplish this with AG grid
 If it is possible, it would surely be difficult.

Cheers