1

I have a custom central admin list and would like to insert it to a custom application page in a way that would make it look exactly like it does if you access the list via its URL - i.e. it should support sorting, filtering, item selection, paging etc.

In my current solution, I bind the list data to SPGridView and it works fine - however, as SPGridView doesn't support auto generation of columns, I have to provide a lot of extra code to handle things like sorting, style, paging, filtering etc. - stuff that works out of the box if I navigate to the list via its SharePoint URL. Another method I found mentioned is first creating a web part and inserting the list there, then showing the web part in my application page - is this the only alternative or is there a more direct way?

1 Answer 1

1

You can actually add XSLTListViewWebPart control in your Application Page and that should work exactly the same as list default page..

See XSLTListViewWebpart in Sharepoint 2010 Uncovered

Download the XSLTListViewWebPart Declaration, Set appropriate properties and you are good to go..

1
  • 1
    Seems that using this web part in application pages is not recommended and can cause various problems: link
    – w128
    Commented Jun 20, 2014 at 9:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.