SharePoint 2010: Weird problem with CQWP with a custom itemstyle.xsl -file.

Hello. I created a custom CQWP which basically does nothing but deploys customized xsl-file. Everything works fine when my cqwp is viewed by admin, but when page is viewed by standard user I get an error saying: Unable to display this Web Part. To troubleshoot the problem, open this Web page in a Microsoft SharePoint Foundation [...]

 Error while executing web part: System.Xml.Xsl.XslLoadException: XSLT compile error. An error occurred
at (1,456). ---> System.Net.WebException: The remote server returned an error: (401) Unauthorized.    
 at System.Net.HttpWebRequest.GetResponse()    
 at System.Xml.XmlDownloadManager.GetNonFileStream(Uri uri, ICredentials credentials)    
 at System.Xml.XmlUrlResolver.GetEntity(Uri absoluteUri, String role, Type ofObjectToReturn)    
 at Microsoft.SharePoint.WebPartPages.WSSXmlUrlResolver.GetEntity(Uri absoluteUri, String role, Type ofObjectToReturn)    
 at System.Xml.Xsl.Xslt.XsltLoader.CreateReader(Uri uri, XmlResolver xmlResolver)    
 at System.Xml.Xsl.Xslt.XsltLoader.LoadStylesheet(Uri uri, Boolean include)    
 at System.Xml.Xsl.Xslt.XsltLoader.LoadStylesheet(XmlReader reader, Boolean include)     -
-- End of inner exception stack trace ---    
 at System.Xml.Xsl.Xslt.XsltLoader.LoadStylesheet(XmlReader reader, Boolean include)    
 at System.Xml.Xsl.Xslt.XsltLoader.Load(Compiler compiler, Object stylesheet, XmlResolver xmlResolver)    
 at System.Xml.Xsl.Xslt.Compiler.Compile(Object stylesheet, XmlResolver xmlResolver, QilExpression& qil)    
 at System.Xml.Xsl.XslCompiledTransform.CompileXsltToQil(Object stylesheet, XsltSettings settings, XmlResolver stylesheetResolver)    
 at System.Xml.Xsl.XslCompiledTransform.LoadInternal(Object stylesheet, XsltSettings settings, XmlResolver stylesheetResolver)    
 at System.Xml.Xsl.XslCompiledTransform.Load(XmlReader stylesheet, XsltSettings settings, XmlResolver stylesheetResolver)    
 at Microsoft.SharePoint.WebPartPages.DataFormWebPart.LoadXslCompiledTransform(WSSXmlUrlResolver someXmlResolver)    
 at Microsoft.SharePoint.WebPartPages.DataFormWebPart.GetXslCompiledTransform()    
 at Microsoft.SharePoint.WebPartPages.DataFormWebPart.PrepareAndPerformTransform(Boolean bDeferExecuteTransform)

Open in new window


LVL 1
tolppaAsked:
Who is Participating?
 
svetayeCommented:
The content query web part works only with files from the Style Library/ XSL Style Sheets on the site collection level. You can change the name of the file to some custom name and place it to this directory.Then you need to redirect you web part to this file instead of the default item style file.
0
 
svetayeCommented:
Hello,
Please recheck that you have published the ItemStyle.xsl file to everyone.
Try to perform check-out/check-in again and publish it as aprimary version.
I hope it helps.
0
 
tolppaAuthor Commented:
Actually I realized that I did not deploy (vs) my custom itemstyle correct folder but created a new folder for my customized itemstyle. Perhaps ordinary users don't have enougth privileges to use that folder? Is it possible to give them authority to use that folder?
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.