IAddtoGallery Interface
The IAddtoGallery interface defines a property that allows a Web Part to add menu items to the Add Web Parts gallery tool pane.
Public Properties
The following table shows the properties of the IAddtoGallery interface, the data type of each property, and a brief description of each.
Name | Data Type | Description |
---|---|---|
GalleryOptions | String | Gets the XML fragment that defines the menu commands added to the menu of the Add Web Parts gallery tool pane. |
Thread Safety
Any public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Any instance members are not guaranteed to be thread safe.
Example
The following code example shows a Web Part class that implements the IAddtoGallery interface and sets the GalleryOptions property to define two menu commands that extend the menu of the Add Web Parts tool pane. For information on the format of the XML fragment use to define menu commands, see the GalleryOptions property topic.
Requirements
Namespace: Microsoft.SharePoint.WebPartPages
Platforms: Windows Server 2003
Assembly: Windows SharePoint Services (in Microsoft.SharePoint.dll)
Security: Code Access Security