EditableDesignerRegion Class
Represents an editable content region within the design-time markup for the associated control.
Assembly: System.Design (in System.Design.dll)
The EditableDesignerRegion type exposes the following members.
| Name | Description | |
|---|---|---|
![]() | EditableDesignerRegion(ControlDesigner, String) | Initializes a new instance of the EditableDesignerRegion class using the given owner and name. |
![]() | EditableDesignerRegion(ControlDesigner, String, Boolean) | Creates a new instance of the EditableDesignerRegion class using the given owner and name and the initial value of the ServerControlsOnly property. |
| Name | Description | |
|---|---|---|
![]() | Content | Gets or sets the HTML markup for the content of the region. |
![]() | Description | Gets or sets the description for a designer region. (Inherited from DesignerRegion.) |
![]() | Designer | Gets the associated designer component. (Inherited from DesignerObject.) |
![]() | DisplayName | Gets or sets the friendly display name for a designer region. (Inherited from DesignerRegion.) |
![]() | EnsureSize | Gets or sets a value indicating whether the region size is to be explicitly set on the designer region by the design host. (Inherited from DesignerRegion.) |
![]() | Highlight | Gets or sets a value indicating whether to highlight the designer region on the design surface. (Inherited from DesignerRegion.) |
![]() | Name | Gets the name of the object. (Inherited from DesignerObject.) |
![]() | Properties | Gets the object's properties. (Inherited from DesignerObject.) |
![]() | Selectable | Gets or sets a value indicating whether the designer region can be selected by the user on the design surface. (Inherited from DesignerRegion.) |
![]() | Selected | Gets or sets a value indicating whether the designer region is currently selected on the design surface. (Inherited from DesignerRegion.) |
![]() | ServerControlsOnly | Gets or sets a value indicating whether the region can accept only Web server controls. |
![]() | SupportsDataBinding | Gets or sets a value indicating whether the region can be bound to a data source. |
![]() | UserData | Gets or sets optional user data to associate with the designer region. (Inherited from DesignerRegion.) |
| Name | Description | |
|---|---|---|
![]() | Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) |
![]() | GetBounds | Retrieves the size of the designer region on the design surface. (Inherited from DesignerRegion.) |
![]() | GetChildViewRendering | Returns a ViewRendering object containing the design-time HTML markup for the given control. |
![]() | GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() | GetService | Gets a service from the design host, as identified by the provided type. (Inherited from DesignerObject.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object.) |
| Name | Description | |
|---|---|---|
![]() ![]() | IServiceProvider::GetService | For a description of this member, see IServiceProvider::GetService. (Inherited from DesignerObject.) |
Use the EditableDesignerRegion class to help manage templates at design time. A ControlDesigner will use an instance of this class with its GetEditableDesignerRegionContent method to generate HTML markup of the region's content.
This example shows how to create a control with two clickable regions and an EditableDesignerRegion object with two views, or templates. Compile the project, then open the page in a visual designer and switch to design (WYSIWYG) view. There are two clickable views, View1 and View2. Click View1 and drag the CheckBox control from the lower part of the page into the empty designer region just below the clickable regions. Click View2 and drag the RadioButton control into the empty designer region. Click View1 again, and the region with the CheckBox reappears. Click View2 and the region with the RadioButton reappears. Switch back to source view to see how your changes are persisted in the HTML markup
Note |
|---|
Your project must have a reference to the System.Design.dll assembly. |
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.





Note