ControlPersister Class
Provides methods for persisting Web server controls at design-time.
Assembly: System.Design (in System.Design.dll)
| Name | Description | |
|---|---|---|
![]() | Equals(Object) | Determines whether the specified object is equal to the current object.(Inherited from Object.) |
![]() | GetHashCode() | Serves as the default hash function. (Inherited from Object.) |
![]() | GetType() | |
![]() ![]() | PersistControl(Control) | Gets a string of data that represents the persisted form of the specified control. |
![]() ![]() | PersistControl(Control, IDesignerHost) | Gets a string of data that represents the persisted form of the specified control, using the specified designer host. |
![]() ![]() | PersistControl(TextWriter, Control) | Outputs a string of data that represents the persisted form of the specified control to the specified TextWriter. |
![]() ![]() | PersistControl(TextWriter, Control, IDesignerHost) | Outputs a string of data that represents the persisted form of the specified control to the specified TextWriter, using the specified designer host. |
![]() ![]() | PersistInnerProperties(Object, IDesignerHost) | Gets a string of data that can persist the inner properties of the specified control. |
![]() ![]() | PersistInnerProperties(TextWriter, Object, IDesignerHost) | Outputs a string of data that can persist the inner properties of the specified control to the specified TextWriter, using the specified designer host. |
![]() ![]() | PersistTemplate(ITemplate, IDesignerHost) | Gets a string of data that represents the persisted form of the specified template. |
![]() ![]() | PersistTemplate(TextWriter, ITemplate, IDesignerHost) | Writes a string of data that represents the persisted form of the specified template to the specified TextWriter object. |
![]() | ToString() | Returns a string that represents the current object.(Inherited from Object.) |
The ControlPersister class provides methods that can persist a Control control or an ITemplate interface implementation as a string of aspx code. The implementation of these methods is driven by metadata attributes, such as the DefaultValueAttribute, PersistenceModeAttribute, and DesignerSerializationVisibilityAttribute.
Note |
|---|
The Web Forms page designer does not support the ResetPropertyName method that is optionally exposed by Microsoft Windows Forms-based controls for property persistence. |
To create a Control object or an ITemplate interface by parsing a string of control- or template-persistence data, use the ControlParser class methods.
Available since 1.1
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.


