Skip to main content

MVCxClientComboBox Class

A client-side counterpart of the ComboBox and ComboBoxFor extensions.

Declaration

declare class MVCxClientComboBox extends ASPxClientComboBox

Remarks

The following example illustrates how to use the MVCxClientComboBox class.

Note

For a full example, refer to MVC ComboBox Extension - Cascading Combo Boxes.

@Html.DevExpress().ComboBox(settings => {
    settings.Name = "City";
    settings.Properties.TextField = "Name";
    settings.Properties.ValueField = "ID";
    ...
    settings.Properties.ClientSideEvents.BeginCallback = "function(s, e) { e.customArgs['Country'] = Country.GetValue(); }";
}).BindList(CS.Models.City.GetCities(Model.Country)).Bind(Model.City).GetHtml()
...
@Html.DevExpress().ComboBox(settings => {
    settings.Name = "Country";
    settings.Properties.TextField = "Name";
    settings.Properties.ValueField = "ID";
    ...
    settings.Properties.ClientSideEvents.SelectedIndexChanged = "function(s, e) { City.PerformCallback(); }";
}).BindList(CS.Models.Country.GetCountries()).Bind(Model.Country).GetHtml()  
See Also