Kendo dropdown width

前端 未结 7 1172
北恋
北恋 2021-02-07 15:07

Hi can someone tell me how to set width for kendo dropdown? Here is my code sample and it is not working. Anything wrong in that?

$(\"#div1\").kendoDropDownList(         


        
相关标签:
7条回答
  • 2021-02-07 15:39

    If MVC Razor DropDownList HTML helper/wrapper syntax is applied, then you can use method HtmlAttributes to specify the width of dropdown list like:

     @(Html.Kendo().DropDownList()                                                            .Name("myDDL")
    .HtmlAttributes(new { style="width:100px" })
    
    0 讨论(0)
提交回复
热议问题