This project is read-only.


Oct 31, 2009 at 10:14 AM


at first: Thank you very much for your great sharepoint stuff :)

based upon the script/blog "WebPart Connections With Power WebPart 3.0" i wrote a custom webpart.

All is fine, but how to sort the SPGridView columns by click on the column title?

1. try

Subscribe-Event $gridView 'Sorting' 'gridViewSorting'

=> can not be handeld by system event manager

2. try (with and without $this.)

# found many c# examples with this line

$gridView.Sorting += New-Object GridViewSortEventHandler(gridViewSorting)

=> runtime error : method gridViewSorting not found

3. try

without sorting event manager sharepoint throws a runtime error page when the column header is clicked ...

Please help (e.g. with a simple example?)

Thank you very much,