Can I change the html name generated by Html.DropDownListFor?

前端 未结 9 1774
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-02-05 03:04

IDI am using the following code to create a drop down list:

 @for (var index = 0; index < Model.AdminSummaries.Count(); index++) 
            { 
            &         


        
9条回答
  •  半阙折子戏
    2021-02-05 03:51

    Thanks .. it work...adding .Name change the name of the html password attribute

          @Html.PasswordFor(Function(model) model.password, New With {.Autocomplete = "off", .Name = "oldpassword", .id = "oldpassword", .value = Model.password, .readonly = True})
    

提交回复
热议问题