menu

ASP.NET MVC - EJ2

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class TreeGridStackedColumnBuilder - ASP.NETMVC-EJ2 API Reference | Syncfusion

    Show / Hide Table of Contents

    Class TreeGridStackedColumnBuilder

    Inheritance
    System.Object
    Syncfusion.EJ2.ControlBuilder
    TreeGridStackedColumnBuilder
    Namespace: Syncfusion.EJ2.TreeGrid
    Assembly: Syncfusion.EJ2.dll
    Syntax
    public class TreeGridStackedColumnBuilder : ControlBuilder

    Constructors

    TreeGridStackedColumnBuilder()

    Declaration
    public TreeGridStackedColumnBuilder()

    TreeGridStackedColumnBuilder(List<TreeGridStackedColumn>)

    Declaration
    public TreeGridStackedColumnBuilder(List<TreeGridStackedColumn> collection)
    Parameters
    Type Name Description
    System.Collections.Generic.List<TreeGridStackedColumn> collection

    Methods

    Add()

    Declaration
    public void Add()

    AllowEditing(Boolean)

    Controls whether editing is permitted for the column. By default, all columns are editable.

    Declaration
    public TreeGridStackedColumnBuilder AllowEditing(bool allowEditing)
    Parameters
    Type Name Description
    System.Boolean allowEditing
    Returns
    Type
    TreeGridStackedColumnBuilder

    AllowFiltering(Boolean)

    Controls whether the column supports filtering. If set to false, users cannot filter data by this column.

    Declaration
    public TreeGridStackedColumnBuilder AllowFiltering(bool allowFiltering)
    Parameters
    Type Name Description
    System.Boolean allowFiltering
    Returns
    Type
    TreeGridStackedColumnBuilder

    AllowReordering(Boolean)

    Enables or disables the reordering of this column via drag-and-drop. Allows for dynamic column adjustments.

    Declaration
    public TreeGridStackedColumnBuilder AllowReordering(bool allowReordering)
    Parameters
    Type Name Description
    System.Boolean allowReordering
    Returns
    Type
    TreeGridStackedColumnBuilder

    AllowResizing(Boolean)

    Determines if this column can be resized. If false, the column size is fixed.

    Declaration
    public TreeGridStackedColumnBuilder AllowResizing(bool allowResizing)
    Parameters
    Type Name Description
    System.Boolean allowResizing
    Returns
    Type
    TreeGridStackedColumnBuilder

    AllowSorting(Boolean)

    Specifies whether sorting is enabled for this column. Set to false to prevent sort actions.

    Declaration
    public TreeGridStackedColumnBuilder AllowSorting(bool allowSorting)
    Parameters
    Type Name Description
    System.Boolean allowSorting
    Returns
    Type
    TreeGridStackedColumnBuilder

    ClipMode(ClipMode)

    Determines how overflow content is handled within a cell. Options include: Clip: Truncates the content. Ellipsis: Shows ellipsis for overflow. EllipsisWithTooltip: Shows ellipsis and tooltip on hover.

    Declaration
    public TreeGridStackedColumnBuilder ClipMode(ClipMode clipMode)
    Parameters
    Type Name Description
    ClipMode clipMode
    Returns
    Type
    TreeGridStackedColumnBuilder

    Columns(Object)

    Defines stacked columns

    Declaration
    public TreeGridStackedColumnBuilder Columns(object columns)
    Parameters
    Type Name Description
    System.Object columns
    Returns
    Type
    TreeGridStackedColumnBuilder

    Columns(String[])

    Defines stacked columns

    Declaration
    public TreeGridStackedColumnBuilder Columns(string[] columns)
    Parameters
    Type Name Description
    System.String[] columns
    Returns
    Type
    TreeGridStackedColumnBuilder

    Commands(Object)

    Provides built-in command button options for cells. Options include Edit, Delete, Save, and Cancel. Custom command button implementations are possible.

    Declaration
    public TreeGridStackedColumnBuilder Commands(object commands)
    Parameters
    Type Name Description
    System.Object commands
    Returns
    Type
    TreeGridStackedColumnBuilder

    CustomAttributes(Object)

    Enables the addition of CSS styles and attributes for the content cells in a particular column.

    Declaration
    public TreeGridStackedColumnBuilder CustomAttributes(object customAttributes)
    Parameters
    Type Name Description
    System.Object customAttributes
    Returns
    Type
    TreeGridStackedColumnBuilder

    DefaultValue(String)

    Sets default values when new records are added to the TreeGrid involving this column.

    Declaration
    public TreeGridStackedColumnBuilder DefaultValue(string defaultValue)
    Parameters
    Type Name Description
    System.String defaultValue
    Returns
    Type
    TreeGridStackedColumnBuilder

    DisableHtmlEncode(Boolean)

    If set to true, the HTML content within header and content cells is encoded to prevent injection attacks.

    Declaration
    public TreeGridStackedColumnBuilder DisableHtmlEncode(bool disableHtmlEncode)
    Parameters
    Type Name Description
    System.Boolean disableHtmlEncode
    Returns
    Type
    TreeGridStackedColumnBuilder

    DisplayAsCheckBox(Boolean)

    Displays the column value as a checkbox instead of a Boolean value when set to true.

    Declaration
    public TreeGridStackedColumnBuilder DisplayAsCheckBox(bool displayAsCheckBox)
    Parameters
    Type Name Description
    System.Boolean displayAsCheckBox
    Returns
    Type
    TreeGridStackedColumnBuilder

    Edit(Object)

    Allows customizing the default edit cell through the IEditCell object for more control over editing.

    Declaration
    public TreeGridStackedColumnBuilder Edit(object edit)
    Parameters
    Type Name Description
    System.Object edit
    Returns
    Type
    TreeGridStackedColumnBuilder

    EditType(String)

    Specifies the component type used for editing cells within this column.

    Declaration
    public TreeGridStackedColumnBuilder EditType(string editType)
    Parameters
    Type Name Description
    System.String editType
    Returns
    Type
    TreeGridStackedColumnBuilder

    Field(String)

    Specifies the field name in the data source to which the column is bound. This field is used for operations like sorting and filtering. The field name must be a valid JavaScript identifier, beginning with a letter and avoiding spaces and special characters.

    Declaration
    public TreeGridStackedColumnBuilder Field(string field)
    Parameters
    Type Name Description
    System.String field
    Returns
    Type
    TreeGridStackedColumnBuilder

    Filter(Object)

    Customizes filter options for the column, enabling specialized filtering functionality.

    Declaration
    public TreeGridStackedColumnBuilder Filter(object filter)
    Parameters
    Type Name Description
    System.Object filter
    Returns
    Type
    TreeGridStackedColumnBuilder

    FilterBarTemplate(Object)

    Allows for a custom component within the filter bar, facilitating advanced filter interfaces. Includes create and read functions for custom component management.

    Declaration
    public TreeGridStackedColumnBuilder FilterBarTemplate(object filterBarTemplate)
    Parameters
    Type Name Description
    System.Object filterBarTemplate
    Returns
    Type
    TreeGridStackedColumnBuilder

    Format(String)

    Formats the displayed value of the column without affecting the underlying data. Supports standard and custom formats for numbers and dates.

    Declaration
    public TreeGridStackedColumnBuilder Format(string format)
    Parameters
    Type Name Description
    System.String format
    Returns
    Type
    TreeGridStackedColumnBuilder

    Formatter(Object)

    Allows for custom cell content formatting using an external method, executed prior to rendering.

    Declaration
    public TreeGridStackedColumnBuilder Formatter(object formatter)
    Parameters
    Type Name Description
    System.Object formatter
    Returns
    Type
    TreeGridStackedColumnBuilder

    Freeze(FreezeDirection)

    Determines which side (left, right, or center) the column should be frozen on.

    Declaration
    public TreeGridStackedColumnBuilder Freeze(FreezeDirection freeze)
    Parameters
    Type Name Description
    FreezeDirection freeze
    Returns
    Type
    TreeGridStackedColumnBuilder

    HeaderTemplate(String)

    Customizes the header content with a template, defined as a string or an HTML element ID.

    Declaration
    public TreeGridStackedColumnBuilder HeaderTemplate(string headerTemplate)
    Parameters
    Type Name Description
    System.String headerTemplate
    Returns
    Type
    TreeGridStackedColumnBuilder

    HeaderText(String)

    Specifies the text displayed in the column header. If omitted, the field value is used as the header text.

    Declaration
    public TreeGridStackedColumnBuilder HeaderText(string headerText)
    Parameters
    Type Name Description
    System.String headerText
    Returns
    Type
    TreeGridStackedColumnBuilder

    HeaderTextAlign(TextAlign)

    Aligns the text in the column header. By default, the alignment corresponds to other content alignments.

    Declaration
    public TreeGridStackedColumnBuilder HeaderTextAlign(TextAlign headerTextAlign)
    Parameters
    Type Name Description
    TextAlign headerTextAlign
    Returns
    Type
    TreeGridStackedColumnBuilder

    HideAtMedia(String)

    Adjusts column visibility based on Media Queries. Accepts valid CSS media query strings for responsive adjustments.

    Declaration
    public TreeGridStackedColumnBuilder HideAtMedia(string hideAtMedia)
    Parameters
    Type Name Description
    System.String hideAtMedia
    Returns
    Type
    TreeGridStackedColumnBuilder

    IsFrozen(Boolean)

    Allows the column to be frozen, keeping it stationary while scrolling horizontally through the grid.

    Declaration
    public TreeGridStackedColumnBuilder IsFrozen(bool isFrozen)
    Parameters
    Type Name Description
    System.Boolean isFrozen
    Returns
    Type
    TreeGridStackedColumnBuilder

    IsIdentity(Boolean)

    Identifies the column as an identity column in database terms, if set to true.

    Declaration
    public TreeGridStackedColumnBuilder IsIdentity(bool isIdentity)
    Parameters
    Type Name Description
    System.Boolean isIdentity
    Returns
    Type
    TreeGridStackedColumnBuilder

    IsPrimaryKey(Boolean)

    Identifies the column as a primary key if set to true, enforcing uniqueness.

    Declaration
    public TreeGridStackedColumnBuilder IsPrimaryKey(bool isPrimaryKey)
    Parameters
    Type Name Description
    System.Boolean isPrimaryKey
    Returns
    Type
    TreeGridStackedColumnBuilder

    LockColumn(Boolean)

    Prevents column reordering when set to true, locking the column into a set position.

    Declaration
    public TreeGridStackedColumnBuilder LockColumn(bool lockColumn)
    Parameters
    Type Name Description
    System.Boolean lockColumn
    Returns
    Type
    TreeGridStackedColumnBuilder

    MaxWidth(Double)

    Defines the maximum allowable width of the column in pixels or as a percentage, preventing resizing beyond this limit.

    Declaration
    public TreeGridStackedColumnBuilder MaxWidth(double maxWidth)
    Parameters
    Type Name Description
    System.Double maxWidth
    Returns
    Type
    TreeGridStackedColumnBuilder

    MaxWidth(String)

    Defines the maximum allowable width of the column in pixels or as a percentage, preventing resizing beyond this limit.

    Declaration
    public TreeGridStackedColumnBuilder MaxWidth(string maxWidth)
    Parameters
    Type Name Description
    System.String maxWidth
    Returns
    Type
    TreeGridStackedColumnBuilder

    MinWidth(Double)

    Determines the minimum width of the column in pixels or percentage. This ensures the column does not shrink below this size.

    Declaration
    public TreeGridStackedColumnBuilder MinWidth(double minWidth)
    Parameters
    Type Name Description
    System.Double minWidth
    Returns
    Type
    TreeGridStackedColumnBuilder

    MinWidth(String)

    Determines the minimum width of the column in pixels or percentage. This ensures the column does not shrink below this size.

    Declaration
    public TreeGridStackedColumnBuilder MinWidth(string minWidth)
    Parameters
    Type Name Description
    System.String minWidth
    Returns
    Type
    TreeGridStackedColumnBuilder

    ShowCheckbox(Boolean)

    Displays checkboxes in the column when enabled, allowing for selections and certain operations.

    Declaration
    public TreeGridStackedColumnBuilder ShowCheckbox(bool showCheckbox)
    Parameters
    Type Name Description
    System.Boolean showCheckbox
    Returns
    Type
    TreeGridStackedColumnBuilder

    ShowColumnMenu(Boolean)

    Decides if the column menu should be available, providing options for column customization.

    Declaration
    public TreeGridStackedColumnBuilder ShowColumnMenu(bool showColumnMenu)
    Parameters
    Type Name Description
    System.Boolean showColumnMenu
    Returns
    Type
    TreeGridStackedColumnBuilder

    ShowInColumnChooser(Boolean)

    Determines whether the column should appear in the Column Chooser. Set to false to exclude it.

    Declaration
    public TreeGridStackedColumnBuilder ShowInColumnChooser(bool showInColumnChooser)
    Parameters
    Type Name Description
    System.Boolean showInColumnChooser
    Returns
    Type
    TreeGridStackedColumnBuilder

    SortComparer(Object)

    Provides a custom sort comparer property to control how sorting is handled for this column's data.

    Declaration
    public TreeGridStackedColumnBuilder SortComparer(object sortComparer)
    Parameters
    Type Name Description
    System.Object sortComparer
    Returns
    Type
    TreeGridStackedColumnBuilder

    SortComparer(String)

    Provides a custom sort comparer property to control how sorting is handled for this column's data.

    Declaration
    public TreeGridStackedColumnBuilder SortComparer(string sortComparer)
    Parameters
    Type Name Description
    System.String sortComparer
    Returns
    Type
    TreeGridStackedColumnBuilder

    Template(String)

    Customizes the rendering of cell content using either a template string or HTML element ID.

    Declaration
    public TreeGridStackedColumnBuilder Template(string template)
    Parameters
    Type Name Description
    System.String template
    Returns
    Type
    TreeGridStackedColumnBuilder

    TextAlign(TextAlign)

    Specifies the horizontal alignment for the column content and header. Options include alignment to the left, center, or right.

    Declaration
    public TreeGridStackedColumnBuilder TextAlign(TextAlign textAlign)
    Parameters
    Type Name Description
    TextAlign textAlign
    Returns
    Type
    TreeGridStackedColumnBuilder

    Type(String)

    Defines the type of data stored in the column, which may be string, number, date, or other types.

    Declaration
    public TreeGridStackedColumnBuilder Type(string type)
    Parameters
    Type Name Description
    System.String type
    Returns
    Type
    TreeGridStackedColumnBuilder

    Uid(String)

    Retrieves the unique identifier for the column. This UID is used internally to reference and manipulate the column.

    Declaration
    public TreeGridStackedColumnBuilder Uid(string uid)
    Parameters
    Type Name Description
    System.String uid
    Returns
    Type
    TreeGridStackedColumnBuilder

    ValidationRules(Object)

    Establishes validation rules to ensure data integrity during creation and updates.

    Declaration
    public TreeGridStackedColumnBuilder ValidationRules(object validationRules)
    Parameters
    Type Name Description
    System.Object validationRules
    Returns
    Type
    TreeGridStackedColumnBuilder

    ValueAccessor(Object)

    Applies custom cell values using an external function, allowing for dynamic display adjustments.

    Declaration
    public TreeGridStackedColumnBuilder ValueAccessor(object valueAccessor)
    Parameters
    Type Name Description
    System.Object valueAccessor
    Returns
    Type
    TreeGridStackedColumnBuilder

    ValueAccessor(String)

    Applies custom cell values using an external function, allowing for dynamic display adjustments.

    Declaration
    public TreeGridStackedColumnBuilder ValueAccessor(string valueAccessor)
    Parameters
    Type Name Description
    System.String valueAccessor
    Returns
    Type
    TreeGridStackedColumnBuilder

    Visible(Boolean)

    Toggles the visibility of the column. Set to false to hide the column from view. Columns are visible by default.

    Declaration
    public TreeGridStackedColumnBuilder Visible(bool visible)
    Parameters
    Type Name Description
    System.Boolean visible
    Returns
    Type
    TreeGridStackedColumnBuilder

    Width(Double)

    Sets the column's width in pixels or as a percentage. This defines how the column will occupy space in the grid.

    Declaration
    public TreeGridStackedColumnBuilder Width(double width)
    Parameters
    Type Name Description
    System.Double width
    Returns
    Type
    TreeGridStackedColumnBuilder

    Width(String)

    Sets the column's width in pixels or as a percentage. This defines how the column will occupy space in the grid.

    Declaration
    public TreeGridStackedColumnBuilder Width(string width)
    Parameters
    Type Name Description
    System.String width
    Returns
    Type
    TreeGridStackedColumnBuilder
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved