Hi Kendo Team,
I'm in the process of creating a page that uses MultiSelect with 5 values inside of it. My objective is as users select the values a completely different set of checkboxes begin to enable or disable themselves based on the selections in the MS. Unfortunately, it isn't working and I'm not entirely sure why.
@{
var funds = new List<SelectListItem> {
new SelectListItem() {
Text = "Value 1", Value = "1"
},
new SelectListItem() {
Text = "Value 2", Value = "2"
},
new SelectListItem() {
Text = "Value 3", Value = "3"
},
new SelectListItem() {
Text = "Value 4", Value = "4"
},
new SelectListItem() {
Text = "Value 5", Value = "5"
}
};
}
@(Html.Kendo().MultiSelect()
.Name("select")
.DataTextField("Text")
.DataValueField("Value")
.BindTo(funds)
.Placeholder("Select Values ...")
.Events ( e =>
{
.Select("select")
}
)
function select(e) {
var values = this.value();
if ($.inArray("1", values) != -1) {
$("group1").removeAttr("disabled");
}
else {
$("group1").attr("disabled", true)
}
};
I'm in the process of creating a page that uses MultiSelect with 5 values inside of it. My objective is as users select the values a completely different set of checkboxes begin to enable or disable themselves based on the selections in the MS. Unfortunately, it isn't working and I'm not entirely sure why.
@{
var funds = new List<SelectListItem> {
new SelectListItem() {
Text = "Value 1", Value = "1"
},
new SelectListItem() {
Text = "Value 2", Value = "2"
},
new SelectListItem() {
Text = "Value 3", Value = "3"
},
new SelectListItem() {
Text = "Value 4", Value = "4"
},
new SelectListItem() {
Text = "Value 5", Value = "5"
}
};
}
@(Html.Kendo().MultiSelect()
.Name("select")
.DataTextField("Text")
.DataValueField("Value")
.BindTo(funds)
.Placeholder("Select Values ...")
.Events ( e =>
{
.Select("select")
}
)
function select(e) {
var values = this.value();
if ($.inArray("1", values) != -1) {
$("group1").removeAttr("disabled");
}
else {
$("group1").attr("disabled", true)
}
};