VB.NET - how to disable enable asp:listbox from javascript
Asked By shoaib mansoori on 31-Dec-12 11:31 AM
Hi all
i have on asp:listbox in my page now i want to disable enable this list box but i couldn't do.
i tried many methods like that
document.getelementbyid("lstcountry").disabled = true
.attr('disabled',disabled')
.attribute.add('disabled')
and other method alos but i couldn't do
so plz help me out..
Robbe Morris replied to shoaib mansoori on 31-Dec-12 01:17 PM
Are you sure the actual "id" rendered in the browser uses your lstcountry? If you do not have the client id set to "static", then ASP.NET will create its own unique "id" when it goes to the browser.
Do a view source on your page after it has rendered to double check.