SharePoint administration pages

A quick note - possibly "note to self" - about how you can add administration pages to central administration ("CA").

  • Start with an empty SharePoint project.

  • Add a mapped folder - to Template/admin.

  • Add an application page to this folder. This is a three step process; add the page, move it from the layouts folder (where Visual Studio decided that you really wanted it), and rename the namespace.

Next you'll want to add this page to CA. Do this by adding a custom action group and a custom action. Cksdev supports both, and you'll find better information about this elsewhere. I wanted my page to appear under "General application settings" so for my action group I chose "Location="Microsoft.SharePoint.Administration.GeneralApplicationSettings"". The UrlAction should point to your admin page.

  <CustomAction Description="Specify the settings for the Contoso module at web application level"
                Title="Web application settings"
                GroupId="Contoso.Administration.Settings"
                Id="Contoso.RequestModule.WebApp.Settings"
                Location="Microsoft.SharePoint.Administration.GeneralApplicationSettings"
                RequireSiteAdministrator="true"
                Sequence="1000"
                 >
   
 

The empty page is probably not what we want.

Break open one of the existing admin pages under C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\ADMIN to get an idea of how you should do this.

You'll need a

inside the body placeholder, you may want a WebApplicationSelector and a ButtonSection, and you will certainly need an InputFormSection - mostly to give it the same look and feel as the builtin CA pages.

Hope this helps - even if it only helps a future me. :-)

This article is part of the GWB Archives. Original Author: Norgean

New on Geeks with Blogs

  • We Won The One Award I Actually Care About

    Full Scale made the Inc. 5000 for the fifth year straight, the 12th listing across my three companies. Here is why the one award you cannot buy is worth stopping for.

  • Your Customers Build the Features Now

    I let a tool I liked sit dead for a year rather than build the features I wanted. An MCP server meant I never had to, and your customers can do the same to your product.

  • Get the Size of a Directory in Linux the Easy Way

    du -sh for the quick answer, ncdu for the cleanup, df for the disk itself: every command for checking directory size in Linux, plus why du and df never agree.

  • Vim Search and Replace: The Ultimate Guide

    One :%s command replaces every match in a file before a find dialog would even open. The Vim substitute patterns worth the muscle memory: flags, ranges, capture groups, and multi-file edits.