Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

DataView Filter Error

  Asked By: Katharine    Date: Jan 08    Category: Sharepoint    Views: 2013

I have a document library in which I would like to filter based on a substring
of the file name. Basically, I'm wanting to only show the documents in which
there is a underscore for the fifth letter of the "Name" field.

I created a document library view, opened in SPD and converted it to a data
I clicked on Filter and then checked ADD XSLT filtering and clicked the Edit

I added the following code to the filter:


I click Ok and get the following message:
Failed setting processor stylesheet: 0x80004005: Expression must evaluate to a
node set.

Could someone help me with this? I'm not that familiar with doing advanced
coding in a dataview so I'm not sure what I'm doing wrong.



1 Answer Found

Answer #1    Answered By: Trupti Patil     Answered On: Jan 08

added  a view  of a document  library to a web page then converted  it to an XSLT
data view using SharePoint Designer. I then went into the Filter, checked  Add
XSLT filtering  and clicked  Edit. The document library  happened to have a
document with an underscore as the seventh character in the name. I added field
names and XSLT functions using the dialog and ended up with this filter:


This seems to work fine. I suspect the issue is that you have put in the full
xpath to the attribute in the filter. The filter  is applied record by record
anyway, so it just needs the attribute name.

Didn't find what you were looking for? Find more on DataView Filter Error Or get search suggestion and latest updates.