This documentation is archived and is not being maintained.

Custom Action

Windows SharePoint Services 3

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

A custom action represents a link, toolbar button, menu item, or any control that can be added to a toolbar or menu that a user sees. Custom actions can be bound to list type, content type, file type, or programmatic identifier (ProgID).

When you use a CustomAction element to add a control to toolbars, standard ASP.NET controls and user controls are supported, such as text boxes or option buttons. However, if you add a control to the drop-down menu of a toolbar (for example, to the Actions menu of the list view toolbar), this control can only instantiate menu items in the drop-down menu. In other words, you cannot add a Web Part or an arbitrary control to a drop-down menu.

Possible scopes:

  • Farm: Yes

  • Web Application: Yes

  • Site Collection: Yes

  • Web Site: Yes

When a custom action is activated, the custom toolbars, menu items, and links associated with the custom action are displayed and operate in their respective locations.

When a custom action is deactivated, the custom toolbars, menu items, and links associated with it become inoperative. They are not displayed in any of their respective locations.

When you install Windows SharePoint Services, ContentTypeSettings and SiteSettings folders are created in the Template\Features directory. These folders each contain a Feature.xml file, as well as ContentTypeSettings.xml and SiteSettings.xml files, respectively, which the Feature.xml file references. The ContentTypeSettings file specifies actions for editing content types in the page ManageContentType.aspx, and the SiteSettings file specifies administrative actions that are displayed on Settings.aspx.

For more information about the file format for custom actions, see Custom Action Definitions.