Class PropertyEditorControl
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Implements
Namespace: DotNetNuke.UI.WebControls
Assembly: DotNetNuke.dll
Syntax
public class PropertyEditorControl : WebControl
Constructors
| Improve this Doc View SourcePropertyEditorControl()
Initializes a new instance of the PropertyEditorControl class.
Declaration
public PropertyEditorControl()
Properties
| Improve this Doc View SourceAutoGenerate
Gets or sets a value indicating whether the editor Autogenerates its editors.
Declaration
public bool AutoGenerate { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
DataSource
Gets or sets the DataSource that is bound to this control.
Declaration
public object DataSource { get; set; }
Property Value
Type | Description |
---|---|
System.Object |
DisplayMode
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
public EditorDisplayMode DisplayMode { get; set; }
Property Value
Type | Description |
---|---|
EditorDisplayMode |
EditControlStyle
Gets the value of the Field Style.
Declaration
public Style EditControlStyle { get; }
Property Value
Type | Description |
---|---|
Style |
EditControlWidth
Gets or sets the width of the Edit Control Column.
Declaration
public Unit EditControlWidth { get; set; }
Property Value
Type | Description |
---|---|
Unit |
EditMode
Gets or sets the Edit Mode of the Editor.
Declaration
public PropertyEditorMode EditMode { get; set; }
Property Value
Type | Description |
---|---|
PropertyEditorMode |
EnableClientValidation
Gets or sets a value indicating whether gets and sets a flag indicating whether the Validators should use client-side validation.
Declaration
public bool EnableClientValidation { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ErrorStyle
Gets the value of the Error Style.
Declaration
public Style ErrorStyle { get; }
Property Value
Type | Description |
---|---|
Style |
Fields
Gets a collection of fields to display if AutoGenerate is false. Or the collection of fields generated if AutoGenerate is true.
Declaration
public ArrayList Fields { get; }
Property Value
Type | Description |
---|---|
ArrayList | A collection of FieldEditorControl objects. |
GroupByMode
Gets or sets the grouping mode.
Declaration
public GroupByMode GroupByMode { get; set; }
Property Value
Type | Description |
---|---|
GroupByMode |
GroupHeaderIncludeRule
Gets or sets a value indicating whether to add a <hr> to the Group Header.
Declaration
public bool GroupHeaderIncludeRule { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
GroupHeaderStyle
Gets the value of the Group Header Style.
Declaration
public Style GroupHeaderStyle { get; }
Property Value
Type | Description |
---|---|
Style |
Groups
Gets or sets the grouping order.
Declaration
public string Groups { get; set; }
Property Value
Type | Description |
---|---|
System.String | A comma-delimited list of categories/groups. |
HelpDisplayMode
Gets or sets whether the control displays Help.
Declaration
public HelpDisplayMode HelpDisplayMode { get; set; }
Property Value
Type | Description |
---|---|
HelpDisplayMode |
HelpStyle
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
public Style HelpStyle { get; }
Property Value
Type | Description |
---|---|
Style |
IsDirty
Gets a value indicating whether any of the properties have been changed.
Declaration
public bool IsDirty { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
IsValid
Gets a value indicating whether all of the properties are Valid.
Declaration
public bool IsValid { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
ItemStyle
Gets the value of the Label Style.
Declaration
public Style ItemStyle { get; }
Property Value
Type | Description |
---|---|
Style |
LabelMode
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
public LabelMode LabelMode { get; set; }
Property Value
Type | Description |
---|---|
LabelMode |
LabelStyle
Gets the value of the Label Style.
Declaration
public Style LabelStyle { get; }
Property Value
Type | Description |
---|---|
Style |
LabelWidth
Gets or sets the width of the Label Column.
Declaration
public Unit LabelWidth { get; set; }
Property Value
Type | Description |
---|---|
Unit |
LocalResourceFile
Gets or sets the Local Resource File for the Control.
Declaration
public string LocalResourceFile { get; set; }
Property Value
Type | Description |
---|---|
System.String |
RequiredUrl
Gets or sets the Url of the Required Image.
Declaration
public string RequiredUrl { get; set; }
Property Value
Type | Description |
---|---|
System.String |
ShowRequired
Gets or sets a value indicating whether the Required icon is used.
Declaration
public bool ShowRequired { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ShowVisibility
Gets or sets a value indicating whether the Visibility control is used.
Declaration
public bool ShowVisibility { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
SortMode
Gets or sets whether to sort properties.
Declaration
public PropertySortType SortMode { get; set; }
Property Value
Type | Description |
---|---|
PropertySortType | The Sort Mode of the editor. |
Remarks
By default all properties will be sorted.
TagKey
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
protected override HtmlTextWriterTag TagKey { get; }
Property Value
Type | Description |
---|---|
HtmlTextWriterTag |
UnderlyingDataSource
Gets the Underlying DataSource.
Declaration
protected virtual IEnumerable UnderlyingDataSource { get; }
Property Value
Type | Description |
---|---|
IEnumerable | An IEnumerable Boolean. |
User
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
public UserInfo User { get; set; }
Property Value
Type | Description |
---|---|
UserInfo |
VisibilityStyle
Gets the value of the Visibility Style.
Declaration
public Style VisibilityStyle { get; }
Property Value
Type | Description |
---|---|
Style |
Methods
| Improve this Doc View SourceAddEditorRow(Panel, Object)
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
protected virtual void AddEditorRow(Panel container, object obj)
Parameters
Type | Name | Description |
---|---|---|
Panel | container | |
System.Object | obj |
AddEditorRow(Object)
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
protected virtual void AddEditorRow(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj |
AddEditorRow(Table, Object)
AddEditorRow builds a sigle editor row and adds it to the Table.
Declaration
protected virtual void AddEditorRow(Table table, object obj)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The Table Control to add the row to. |
System.Object | obj | Row Data Info. |
Remarks
This method is protected so that classes that inherit from PropertyEditor can modify how the Row is displayed.
AddEditorRow(Table, String, IEditorInfoAdapter)
AddEditorRow builds a sigle editor row and adds it to the Table, using the specified adapter.
Declaration
protected void AddEditorRow(Table table, string name, IEditorInfoAdapter adapter)
Parameters
Type | Name | Description |
---|---|---|
Table | table | The Table Control to add the row to. |
System.String | name | The name of property being added. |
IEditorInfoAdapter | adapter | An IEditorInfoAdapter. |
AddEditorRow(WebControl, String, IEditorInfoAdapter)
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
protected void AddEditorRow(WebControl container, string name, IEditorInfoAdapter adapter)
Parameters
Type | Name | Description |
---|---|---|
WebControl | container | |
System.String | name | |
IEditorInfoAdapter | adapter |
AddFields()
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
protected virtual void AddFields()
AddFields(Table)
AddFields adds the fields that have beend defined in design mode (Autogenerate=false).
Declaration
protected virtual void AddFields(Table tbl)
Parameters
Type | Name | Description |
---|---|---|
Table | tbl | The Table Control to add the row to. |
AddHeader(Table, String)
AddHeader builds a group header.
Declaration
protected virtual void AddHeader(Table tbl, string header)
Parameters
Type | Name | Description |
---|---|---|
Table | tbl | The Table Control that contains the group. |
System.String | header | Table Header. |
Remarks
This method is protected so that classes that inherit from PropertyEditor can modify how the Header is displayed.
CollectionItemAdded(Object, PropertyEditorEventArgs)
Runs when an item is added to a collection type property.
Declaration
protected virtual void CollectionItemAdded(object sender, PropertyEditorEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Object | sender | |
PropertyEditorEventArgs | e |
CollectionItemDeleted(Object, PropertyEditorEventArgs)
Runs when an item is removed from a collection type property.
Declaration
protected virtual void CollectionItemDeleted(object sender, PropertyEditorEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Object | sender | |
PropertyEditorEventArgs | e |
CreateEditor()
CreateEditor creates the control collection.
Declaration
protected virtual void CreateEditor()
DataBind()
Binds the controls to the DataSource.
Declaration
public override void DataBind()
EditorItemCreated(Object, PropertyEditorItemEventArgs)
Runs when an Editor Is Created.
Declaration
protected virtual void EditorItemCreated(object sender, PropertyEditorItemEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Object | sender | |
PropertyEditorItemEventArgs | e |
GetCategory(Object)
GetCategory gets the Category of an object.
Declaration
protected virtual string GetCategory(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj |
Returns
Type | Description |
---|---|
System.String | The category name, or NullString. |
GetGroups(IEnumerable)
GetGroups gets an array of Groups/Categories from the DataSource.
Declaration
protected virtual string[] GetGroups(IEnumerable arrObjects)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable | arrObjects |
Returns
Type | Description |
---|---|
System.String[] | An array of group/category names. |
GetRowVisibility(Object)
GetRowVisibility determines the Visibility of a row in the table.
Declaration
protected virtual bool GetRowVisibility(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | The property. |
Returns
Type | Description |
---|---|
System.Boolean | true if the row is visible, otherwise false. |
ListItemChanged(Object, PropertyEditorEventArgs)
Runs when an Item in the List Is Changed.
Declaration
protected virtual void ListItemChanged(object sender, PropertyEditorEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Object | sender | |
PropertyEditorEventArgs | e |
OnItemAdded(PropertyEditorEventArgs)
Runs when an item is added to a collection type property.
Declaration
protected virtual void OnItemAdded(PropertyEditorEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
PropertyEditorEventArgs | e |
OnItemCreated(PropertyEditorItemEventArgs)
Runs when an Editor is Created.
Declaration
protected virtual void OnItemCreated(PropertyEditorItemEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
PropertyEditorItemEventArgs | e |
OnItemDeleted(PropertyEditorEventArgs)
Runs when an item is removed from a collection type property.
Declaration
protected virtual void OnItemDeleted(PropertyEditorEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
PropertyEditorEventArgs | e |
OnPreRender(EventArgs)
Runs just before the control is rendered.
Declaration
protected override void OnPreRender(EventArgs e)
Parameters
Type | Name | Description |
---|---|---|
EventArgs | e |
Events
| Improve this Doc View SourceItemAdded
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
public event PropertyChangedEventHandler ItemAdded
Event Type
Type | Description |
---|---|
PropertyChangedEventHandler |
ItemCreated
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
public event EditorCreatedEventHandler ItemCreated
Event Type
Type | Description |
---|---|
EditorCreatedEventHandler |
ItemDeleted
The PropertyEditorControl control provides a way to display and edit any properties of any Info class.
Declaration
public event PropertyChangedEventHandler ItemDeleted
Event Type
Type | Description |
---|---|
PropertyChangedEventHandler |