forum

Home / DeveloperSection / Forums / How to create dropdownlist Disabled in ASP.NET Razor MVC

How to create dropdownlist Disabled in ASP.NET Razor MVC

Anonymous User 6960 27-Nov-2014
<div class="form-group">            
        @Html.LabelFor(model => model.CourseStatus, new { @class ="control-label col-md-2" })   
        <divclass="col-md-10">
            @Html.DropDownList("statusList", String.Empty, new { @disbled= disabled})
            @Html.ValidationMessageFor(model => model.CourseStatus)      
        </div>
    </div>

I am new in ASP.NET MVC and RAZOR. I just want to create a disabled dropdownlist. I have already created SelectList name "statusList". Through which I am trying to call the status. but I want to make it disbled and make one status as by default


Updated on 27-Nov-2014
I am a content writter !

Can you answer this question?


Answer

1 Answers

Liked By