ASP.NET MVC ListBox - Server-Side API - Enable / Disable

  • Alfreds FutterkisteALFKI
  • Antonio Moreno TaqueríaANATR
  • Around the HornAROUT
  • Berglunds snabbköpANTON
  • Berglunds snabbköpBERGS
  • Blauer See DelikatessenBLAUS
  • Blondesddsl père et filsBLONP
  • Bólido Comidas preparadasBOLID
  • Bon app'BONAP
  • Bottom-Dollar MarketsBOTTM
   
Enable
 
Disable
The ListBox control provides a property for enabling / disabling the control.

Set the Enabled property to true to enable the ListBox.
Set the Enabled property to false to disable the ListBox.
View - Aspx

    <% Html.Obout(new ListBox("ListBox1")
    {   
        Enabled = true
    }); %>
    
    
View - Razor

    @Html.Obout(new ListBox("ListBox1")
    {   
        Enabled = true
    })