Quantcast
Channel: SharePoint 2010 - Development and Programming forum
Viewing all articles
Browse latest Browse all 11571

Visual Webpart - How to get all documents in a folder and sort them by caml query?

$
0
0

I am making a visual web part for sharepoint 2010. I have a "SPFolder" object and I want to get all items in it, but I want to sort it by a specific field. I want to do this by CAML query instead of using a view.

I am currently doing this by "return library.GetItemsInFolder(library.DefaultView, folder);". It doesn't seem to contain a parameter for a CAML query.

Does anyone know how to do this?

Thanks.



Viewing all articles
Browse latest Browse all 11571

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>