I want to build search criteria by using SPQuery object that searches a list. On application page, there are two textbox Controls, 2 combobox Controls and 2 people picker Controls. The search criteria is based on user input. Users will use any or all of these Control values to search records. I could not find an efficient way to solve this issue. I need some good links or suggestion to solve this.
Tell me more
×
SharePoint Stack Exchange is a question and answer site for
SharePoint enthusiasts. It's 100% free, no registration required.
|
I don't know how to dynamic query using CAML.. but u can do using linq query. for eg.
you can put create dynamic query after where clause based on condition. some links are which helps u.. http://corypeters.net/2009/09/querying-a-sharepoint-list-with-linq/ http://msdn.microsoft.com/en-us/library/ee535491%28v=office.14%29.aspx http://www.codeproject.com/Articles/156014/How-to-use-LINQ-to-Sharepoint |
||||
|
|
|
CAMLEX.NET is good tool to solve you task. From documentation: Dynamic filtering conditions |
||||
|
|
