Gets a collection of custom verbs associated with a WebPart control.
Assembly: System.Web (in System.Web.dll)
Property ValueType: System.Web.UI.WebControls.WebParts.WebPartVerbCollection
Verbs derive from the WebPartVerb class, and provide user interface (UI) actions that users can perform on a WebPart control. Usually verbs are represented in the UI as buttons, links, or menu items. By default, common Web Parts verbs appear on a drop-down verbs menu in each WebPart control's title bar. There are standard verbs for opening, closing, editing, and minimizing a control, and other verbs for exporting a definition for the control or loading a Help file. These verbs are not included in the collection, because the collection contains only custom verbs that you create and return by overriding this property in a derived class.
When you create custom verbs and add them to the WebPart control.collection, you can then access the verbs programmatically from a
Notes to Inheritors:
The following code example demonstrates how to access the TextDisplayWebPart, created in the Example section of the WebPart class overview.property for a custom Web Parts control. This example assumes the use of a custom control,
Note that for the code example to work, you must add a setting in the Web.config file to enable exporting Web Parts description files. Ensure that you have a Web.config file in the same directory as the Web page for this code example. Within the <system.web> section, make sure there is a <webParts> element with an enableExport attribute set to true, as in the following markup.
Load the Web page in a browser. When you click the Display Verb Count button, it accesses the TextDisplayWebPart control, and displays the count in a label. Because no custom verbs have been added to the control in this case, the count is zero.property to get the count of custom verbs for the
Available since 2.0