MVC - Html.DropdownListFor disappearing when selectpicker class is added to HTML attributes

37 views Asked by At

Html.DropdownListFor disappearing when selectpicker class is added to HTML attributes, issue is only is particular partial view. same dropdown is working fine with select picker class added in a view.

I've added correct bootstrap, boot-strap-select, jQuery and popper references to shared layout file in correct order.

This dropdown works fine in a view with selectpicker class added but when it is added to a partial view dropdown is disappearing. After testing with other classes realised selectpicker is the issue. without that dropdown is displaying but without searchable functionality.

Tried looking through various online resources, couldn't figure out a solution.

I'm new to coding world and ASP.net MVC, please advise.

0

There are 0 answers