Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

Im using the webservice to get listitems from a list. The list has a filter on it as well as an eventlistener. The eventlistener triggers every time a new item is added to the list but it is possible that the newly added document won't show up in the filtered view.

In my request to getlistitems I specify the listname, the view name and use a query to retrieve the item using the items guid. I would expect the query to return an empty resultset when the item doesnt exist in the list view, but unfortunately it appears that the view is ignored.

Interestingly enough if I run the getlistitems query without specifying the guid I want I only get the documents specific to the view.

is there a query option or something that I can use to make sure that the list items returned when specifying a guid adhere to the filter on the view?

thanks for your help!

share|improve this question

1 Answer 1

up vote 0 down vote accepted

As per the MSDN documentation for query parameter

If supplied, the value of this parameter overrides either the query within the view specified by the viewName parameter or the query within the default view for the list.

So the filter criteria defined in the view will be ignored here.

share|improve this answer
    
Are you aware of way to get an item but still maintain the list filter? A shove in the right direction on where to look would be enough Im not totally lazy :) –  Anonymous Sep 1 '10 at 16:32
    
I am not really sure if you can maintain the view filter restriction. But you can always design your query to maintain that restriction. –  Vivek Sep 1 '10 at 16:41

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.