Click here to Skip to main content
15,891,704 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
How to filter gridview with 5 checkboxlists for Product search

Checkboxlist1 - ProductList

CheckboxList2 - Age

CheckboxList3 - Gender

CheckboxList4 - Country

CheckboxList5 - Brand

Based on the items checked, the gridview should update results - product image, title of product, and link to product page. This is similar to product search in Ebay.

Any idea? Its very urgent struggling to find solution using ADO.NET entity data model
Linq
Posted
Comments
Kishor Deshpande 16-Jan-13 13:27pm    
Well in this case, you can apply a sort on datasource of your Gridview, suppose I've list to bind with GridView then,
var result = list.OrderByDescending(p => p.ProductList).OrderBy(a => a.Age)....
rose8garden 17-Jan-13 6:45am    
In need subquery to result1(which is list of productids).
result1 - productids
result2 - query of result1(productids) where ageid = ....
result3 - query of result2.....
...
Pass the final value to Gridview

Here I have no idea how to write subqueries in Linq and bind it to Gridview
Nandakishore G N 19-Jan-13 5:38am    
how are you binding the data to gridview?

 
Share this answer
 
Comments
rose8garden 17-Jan-13 6:39am    
Sorry If I did not explain clearly.
Here checkboxlist's is outside of gridview. selected ids of checkboxlists are inputs to gridview to filter output results.
Please refer below link. Might helps you.
http://stackoverflow.com/questions/418609/how-to-do-subquery-in-linq[^]
 
Share this answer
 
hey u got ans of this que?
please post ur ans here me to facing same problem
thank you
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900