it's resolved my issue. I did update the function instead of updating the binding as there are some other values depend on "ddl.DataValueField="Value";
In function I used value instead of description. now my function is: function change() { if (document.getElementById("<%= ddlType.ClientID %>").value == "201") { document.getElementById("<%= fileUpload.ClientID %>").style.display = 'block'; } else { document.getElementById("<%= fileUpload.ClientID %>").style.display = 'none';
Member
7 Points
24 Posts
Re: hide or display FILEUPLOAD CONTROL depends on dropdown value
Apr 27, 2018 07:19 PM|OK29|LINK
Thank you for your suggestion.
In function I used value instead of description. now my function is:
function change() {
if (document.getElementById("<%= ddlType.ClientID %>").value == "201") {
document.getElementById("<%= fileUpload.ClientID %>").style.display = 'block';
}
else { document.getElementById("<%= fileUpload.ClientID %>").style.display = 'none';
}
}