locked
Custom filter in sharepoint 2007 custom list form RRS feed

  • Question

  • I have a custom list form created in SP 2007. I have column called CandidateID. How can I put filter on CandidateID from query string.

    Regards, Surya

    Thursday, March 21, 2013 6:05 PM

Answers

  • Hi Surya,

    Usually filters would apply to a data view web part. And in custom list form, we may need to display the query string in a form field, like CandidateID.

     I’m not sure which one would you like to use, so I will provide the solutions for both of these 2 requirements.

    Pass filter from query string to data view web part

    1. Add a parameter for the data view web part. And select Query string as the Parameter Source. Then give the query string variable.
    2. Add filter to the data view web part and use the parameter we created in step1 as the filter.
    3. You may also refer to xizwyck’s reply in the following thread for more detail steps.
      http://social.msdn.microsoft.com/Forums/en-US/sharepointcustomization/thread/872dccfb-7b89-4076-8983-05359349cdfe/

    We need JavaScript to pass query string data to form field in custom list form. Refer to Marc’s blog.
    http://sympmarc.com/2008/07/11/using-query-string-variables-to-populate-sharepoint-form-fields/

    Thanks & Regards,
    Emir Liu
    TechNet Subscriber Support in forum
    If you have any feedback on our support, please click here.


    Emir Liu
    TechNet Community Support

    • Marked as answer by Emir Liu Thursday, March 28, 2013 6:59 AM
    Friday, March 22, 2013 6:36 AM