本文整理汇总了C#中ComboBox.enable方法的典型用法代码示例。如果您正苦于以下问题:C# ComboBox.enable方法的具体用法?C# ComboBox.enable怎么用?C# ComboBox.enable使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ComboBox
的用法示例。
在下文中一共展示了ComboBox.enable方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OnReady
static void OnReady()
{
var data = new JsArray<ComboBoxConfiguration> {
new ComboBoxConfiguration { text = "12 Angry Men", value = "1" },
new ComboBoxConfiguration{ text = "Il buono, il brutto, il cattivo.", value = "2" },
new ComboBoxConfiguration{ text = "Inception", value = "3" },
new ComboBoxConfiguration{ text = "One Flew Over the Cuckoo's Nest", value = "4" },
new ComboBoxConfiguration{ text = "Pulp Fiction", value = "5" },
new ComboBoxConfiguration{ text = "Schindler's List", value = "6" },
new ComboBoxConfiguration { text = "The Dark Knight", value = "7" },
new ComboBoxConfiguration{ text = "The Godfather", value = "8" },
new ComboBoxConfiguration{ text = "The Godfather = Part II", value = "9" },
new ComboBoxConfiguration{ text = "The Shawshank Redemption", value = "10" },
new ComboBoxConfiguration{ text = "The Shawshank Redemption 2", value = "11" }
};
new jQuery("#products").kendoComboBox(new ComboBoxConfiguration
{
dataTextField = "text",
dataValueField = "value",
dataSourceObject = data
})
.closest(".k-widget")
.attr("id", "products_wrapper");
new jQuery("#filter").kendoDropDownList(new DropDownListConfiguration
{
change = filterTypeOnChanged
});
combobox = new jQuery("#products").data("kendoComboBox").As<ComboBox>();
new jQuery("#enable").click(() => combobox.enable());
new jQuery("#disable").click(() => combobox.enable(false));
new jQuery("#open").click(() => combobox.open());
new jQuery("#close").click(() => combobox.close());
new jQuery("#getValue").click(() => HtmlContext.window.alert(combobox.value()));
new jQuery("#getText").click(() => HtmlContext.window.alert(combobox.value()));
new jQuery("#setValue").click(setValue);
new jQuery("#value").keypress(setValue);
new jQuery("#select").click(setIndex);
new jQuery("#index").keypress(setIndex);
new jQuery("#find").click(setSearch);
new jQuery("#word").keypress(setSearch);
}