Archive for the 'SharePoint' Category
Building A SPGridView Control – Part 4: Filtering Multiple Columns
60 Comments Published February 1st, 2010 in Programming, SharePointIn Part 2 of this series, we added filtering to our ASPGridView. Since then I’ve gotten a lot of questions about implementing multi-column filtering. Again the main reason seems to be “If SharePoint can do it, why can’t we?”. And that’s exactly the kind of question that gets me going 🙂 I love a good […]
Building A SPGridView Control – Part 3: Adding a Context Menu using the SPMenuField
0 Comments Published November 24th, 2009 in Programming, SharePointPrevious parts: Part 1: Introducing the SPGridView Part 2: Filtering Intermezzo: TemplateFields and the RowCommand Event In this part of the series we’ll be adding a context menu to our SPGridView using the SPMenuField control. Using the MenuField can be a bit tricky the first time round since there are a lot of properties involved. […]
When developing custom WebParts and UserControls for SharePoint you often need to access Lists and their content. There is a number of ways to retrieve a List (or more specifically, a SPList instance). For example, if you know the List’s ID (which is a Guid) you can do the following:
Building A SPGridView Control – Intermezzo: TemplateFields and the RowCommand Event
8 Comments Published July 8th, 2009 in Programming, SharePointWelcome to the third installment of my series on the SPGridView. I had planned to tackle menus and the MenuField control in this installment but I got sidetracked by a very interesting problem posted by Josh as a comment to Part 1 of this series. His problem was that for some reason the RowCommand event […]
Building A SPGridView Control – Part 2: Filtering
46 Comments Published May 24th, 2009 in Programming, SharePointWelcome to the second installment of my series on the SPGridView. In Part 1 I introduced the SPGridView, the ObjectDataSource and the SPGridViewPager. The result was a reusable component that supports sorted and paging. In this installment, we will extend the component to support filtering. Filtering is one of the most sought-after features of the […]
Building A SPGridView Control – Part 1: Introducing the SPGridView
50 Comments Published May 1st, 2009 in Programming, SharePointThe SPGridView is one of the most ubiquitous controls used in SharePoint. Every single list in SharePoint (and as we all know there’s lots of those!) uses the SPGridView to display its data in neatly formatted rows. We’re able to sort its data, filter it and click on an item to choose from any options […]
Building A SPGridView Control: ASPGridView
2 Comments Published April 26th, 2009 in Programming, SharePointThere are quite a number of posts concerning the SPGridView. The ones I would particularly recommend are those of Paul Robinson and Robert Fridén. However, most posts are only concerned with a particular feature of the SPGridView, like paging, sorting and menu fields. So I gathered it was a good idea to try and combine […]
For an internal project we were creating a number of custom List Definitions by editing the schema.xml files. When we opened an instance of the List Definition in SharePoint, the fields we had added did not show up in the View, New and Edit forms. Only the Title field was visible. As it turned out, […]
SharePoint Custom Templates and Language Packs
0 Comments Published September 10th, 2008 in Programming, SharePointRecently I’ve been working a lot with the SharePoint standard templates. A client wanted us to build a Web Part that had the look and feel of a standard SharePoint Web Part and the easiest way to achieve that was using templates. Using these, we didn’t have to worry about custom fields, save buttons, validation […]
Loading SharePoint templates from a different location
1 Comment Published September 1st, 2008 in Programming, SharePointIn his excellent post on How SharePoint 2007 Renders Its Content Geoff McElhanon shows how to programmatically load SharePoint-based templates. The code he shows us is as follows: 1 2 3 4 5 6 7 // Initialize template container with our custom template templateContainer = new TemplateContainer(); templateContainer.Template = SPControlTemplateManager.GetTemplateByName(RenderingTemplateId); // Add the container […]
Recent Comments