2X faster development
The ultimate ASP.NET Core UI toolkit to boost your development speed.
In certain cases, changing the dataSource of one dropdown on selecting a value from other dropdown is known as the cascading effect. This effect can be applied to two dropdown controls within Grid upon editing that is explained in detail in this document. Solution The following example explains in detail on how to achieve the cascading effect in Grid for two ForeignKey columns that refreshes the dataSource of one dropdown based on the value selected in another dropdown. Example
HTML:
Javascript:
C#
MVC RAZOR:
C#
ASP.NET
C# ASP.NET CORE HTML C# ANGULAR HTML TS
2. In the ActionComplete events of the Grid, the ValChange function is bound to the Change event of the ejDropDownList. The selected value of the Designation dropdown is passed to the server side on the Ajax call, getting the filtered data from the server side and assigning it to the Country dropdown’s dataSource.
Result: Figure 1Initial rendering of grid
Figure 2On editing a record
Figure 3On changing the value of designation column |
2X faster development
The ultimate ASP.NET Core UI toolkit to boost your development speed.
This page will automatically be redirected to the sign-in page in 10 seconds.