WSS3SDK add actions to the user interface in the site collection

Source: Internet
Author: User
Tags relative

Feature makes it easier to add menus that operate to the Windows SharePoint Services user interface. The following example shows how to add an operation to a variety of menus through feature and actually deploy and activate it.

Location and Group IDs

Before you define a custom action for a specific menu, you must identify the menu by setting its zone information as the appropriate WSS namespace and using WSS to identify the ID of a particular zone ...

For example, if you want to add a custom action to the Site Settings page, you need to set the CustomAction Location property to Microsoft.SharePoint.SiteSettings. The GroupID property is then used to specify a specific area of the page.

Different actions may require different customaction properties to identify the menu where the custom action is placed. However, you may also need to specify additional parameters for the operation, such as specifying a version number, the user permission requirements for the operation, or the relationship to the existing operation in the menu. The following custom action examples show a variety of properties.

URL Tokens

WSS supports the following tokens that can be used before a relative URL address:

~site-site (SPWEB) relative links.

~sitecollection-site collection (SPSite) relative links.

At the same time, you can also use the following notation in the URL:

{ItemId}-the integer ID represents the list item in the list.

{Itemurl}-the URL of the managed list item. For documents in the library only. [Invalid in Beta 2]

{Listid}-represents the GUID for the list.

{SiteURL}-Web site URL (SPWeb).

{Recurrenceid}-duplicate item ID. The token is not available for the context menu of the list item.

Steps

Create a extensions\12\template\features under C:\Program files\common Files\Microsoft Shared\Web server Userinterfacelightup Folder.

Create a feature.xml file in the new Userinterfacelightup folder to provide a list of elements for the Feature, as follows:

<?xml version="1.0" encoding="utf-8" ?>
<Feature Id="GUID"
Title="Light Up"
Description="This example shows how you can light up various areas inside Windows SharePoint Services."
Version="1.0.0.0"
Scope="Site"
xmlns="http://schemas.microsoft.com/sharepoint/">
<ElementManifests>
<ElementManifest Location="Lightup.xml" />
</ElementManifests>
</Feature>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.