DataGridViewAvatarColumn
Namespace: Wisej.Web
Assembly: Wisej.Framework (4.2.0.0)
Defines avatar presentation for DataGridViewAvatarCell cells while retaining their bound values.
- C#
- VB.NET
public class DataGridViewAvatarColumn : DataGridViewColumn, IGridVisualColumn
Public Class DataGridViewAvatarColumn
Inherits DataGridViewColumn
Implements IGridVisualColumn
Presentation belongs to the column. Member paths resolve against the bound record, or sibling column names in unbound grids. Changes refresh grid data. These columns are read-only; cell clicks still raise the inherited grid CellClick event.
Example:
var column = new DataGridViewAvatarColumn { Name = "Avatar", DataPropertyName = "Value" };
grid.Columns.Add(column);
Constructors
DataGridViewAvatarColumn()
Creates the typed template and read-only defaults.
Properties
AutoColor
Boolean: Gets or sets chooses a stable theme palette from the displayed name. (Default: True)
CellTemplate
DataGridViewCell: Gets or sets the required DataGridViewAvatarCell template.
ImageMember
String: Gets or sets image or image-source member path. (Default: "")
ReadOnly
Boolean: Gets or sets whether the user can edit the column's cells. The default is true: the cells have no editor. (Default: True)
Shape
AvatarShape: Gets or sets portrait outline shape. (Default: Circle)
Size
Int32: Gets or sets avatar diameter in pixels, from 12 through 128. (Default: 32)
SubTextMember
String: Gets or sets secondary label member path. (Default: "")
TextMember
String: Gets or sets full name member path; empty uses the cell value. (Default: "")
Methods
Clone()
Clones presentation settings and owned collections without copying event subscriptions.
Returns: Object. An independent column.
OnAvatarClick(e)
Raises AvatarClick even when a derived class has no subscribed handlers.
| Parameter | Type | Description |
|---|---|---|
| e | DataGridViewVisualCellEventArgs | Activated row and server action. |
Events
AvatarClick
EventHandler<DataGridViewVisualCellEventArgs> Occurs on validated AvatarClick activation, without changing the bound record.
Implements
| Name | Description |
|---|---|
| IUserData | Provides access to the UserData and Tag properties associated to the component implementing this interface. |
| IWisejComponent | All wisej components implement this interface. |
| IWisejSerializable | Allows an object to serialize itself. |