How can show all data in the datalist if I click on All in dropdown list
And want I click dog on dropdownlist it will show all the dog item only how can it be done
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Tan Kai KaiPosted Jul 16, 2013, 9:24 AM
Tan Kai KaiPosted Jul 16, 2013, 7:16 AM
Sanjeeb LenkaPosted Jul 16, 2013, 6:57 AM
if(ddlItem.SelectedValue=="ALL")
{
//select all the data and bind to datalist
}
else
{
//select passing the dropdownselected value to database to select corresponding data bind to datalist.
}
ex:- 1st query : Select * form itemtable
2nd query: Select * from itemtable where item='"+ddlItem.SelectedValue+"'
Tan Kai KaiPosted Jul 16, 2013, 6:47 AM
and a datalist
want the dropdownlist show All
I will show all the item from the database but want is show cat
It only show all the item that are cat only and not show all
Ravi ShekharPosted Jul 16, 2013, 5:37 AM
Iftikar HussainPosted Jul 16, 2013, 12:30 AM
Not clear about your query. Can you please provide more details?
Regards,
Iftikar
Tan Kai KaiPosted Jul 15, 2013, 10:34 PM