I ma newbie on jquery UI. Can you please tell why
$('#ddlPanel').data("kendoDropDownList").select($("#ddlPanel")[0].selectedIndex);
Didn't fetch me value after a post back.
I will make that simple. on selecting any value from dropdown, the value should be retained after onclick.
I have tried the above one but results with an undefined value.
<select id="ddlPanel"> <option value="0">Select Business Unit</option> . . </select>
<select id="ddlPanel"> <option value="0">Select Business Unit</option> . . </select>
This is from .cshtml $('#ddlPanel').data("kendoDropDownList").select($("#ddlPanel")[0].selectedIndex);
And i used the above jquery to retain the value after postback
You can do $("#ddlPanel").data("kendoDropDownList").text();
or $('#ddlPanel').data("kendoDropDownList").value();
to get value from DropDownList.. You can refer jsfiddle
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.