ok...i have an existing html form that have a number of fields..one being a dropdown specialty list.
the form does a get to an aspx datagrid written in c# (i did not write this and i need to only modify it until i have time to redo the entire thing so please dont say its all wrong, i know lol)
the filter for the specialty is a loop statement using if...
the dropdown id's are specialty and specialty2
basically i need to change it so that if specialty2 is selected it will filter by both
wha ti have above works but if both are selected....ins tead of filtering by both..i get no results.
the form does a get to an aspx datagrid written in c# (i did not write this and i need to only modify it until i have time to redo the entire thing so please dont say its all wrong, i know lol)
the filter for the specialty is a loop statement using if...
Code:
if (Server.HtmlEncode(arr1[loop1])=="specialty") sWhere += "specialty LIKE '%" + (arr2[loop2])+ "%' AND "; if (Server.HtmlEncode(arr1[loop1])=="specialty2") sWhere += "specialty LIKE '%" + (arr2[loop2])+ "%' AND ";
basically i need to change it so that if specialty2 is selected it will filter by both
wha ti have above works but if both are selected....ins tead of filtering by both..i get no results.