Sitefinity CMS

Telerik.Framework Send comments on this topic.
ToolboxItem Class
See Also  Members   Example 
Telerik.Web Namespace : ToolboxItem Class


Registers given control to be shown in the toolbox when editing a page.

 

Namespace: Telerik.Web
Assembly: Telerik.Framework (in Telerik.Framework.dll)

Syntax

Visual Basic (Declaration) 
Public Class ToolboxItem 
   Implements IToolboxItem 
Visual Basic (Usage)Copy Code
Dim instance As ToolboxItem
C# 
public class ToolboxItem : IToolboxItem  

Example

The following example shows how to create class the inherits from the ToolboxItem class which would be used to register control of the JobList type in the toolbox when editing a page. It aslo change the default settings for the DisplayName and Description properties.
C#Copy Code
/// <summary>
/// Toolbox item class representing JobList control
/// </summary>
[Serializable]
public class JobListToolboxItem : ToolboxItem
{
   
public JobListToolboxItem()
       :
base(typeof(JobList))
   {
       
base.DisplayName = Messages.JobsListTitle;
       
base.Description = Messages.JobDescriptionLabel;
   }
}
    

Remarks

It is recommended to inherit from this class when registering custom controls and override the needed members. The class should be initialized in the module declaration by the WebModule.Controls property.

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also