HtmlForgeX

API Reference

Class

DataTablesSettings

Namespace HtmlForgeX
Assembly HtmlForgeX

Settings sub‑builder for DataTablesTable to keep the root API lean.

Inheritance

  • Object
  • DataTablesSettings

Methods

public DataTablesSettings AccessorForType<T>(String propertyName, Func<T, Object> accessor) #
Returns: DataTablesSettings

Type Parameters

T

Parameters

propertyName String requiredposition: 0
accessor Func<T, Object> requiredposition: 1
AccessorForType``1(System.String propertyName, System.Func{``0,System.Object} accessor) #

Registers a typed accessor for a property on type T. Used by JoinProperty and SmartLabel to read values without reflection.

Parameters

propertyName System.String required
accessor System.Func{``0,System.Object} required
public DataTablesSettings AccordionDefaults(Boolean responsiveInline = true) #
Returns: DataTablesSettings

Applies recommended defaults when a table is rendered inside an accordion/collapse. Currently disables AutoWidth for smoother reveal behavior and allows Responsive to manage columns.

Parameters

responsiveInline System.Boolean = true optionalposition: 0
If true, also enables Responsive with inline details.
public DataTablesSettings AlphabetFilter(Int32 columnIndex = 0) #
Returns: DataTablesSettings

Adds an A–Z alphabet filter toolbar that filters rows by the starting letter in the chosen column.

Parameters

columnIndex System.Int32 = 0 optionalposition: 0
ApplyTransformers() #

Applies transformer and summarization settings to the underlying table. Invoked automatically when the Settings(...) block completes.

public DataTablesSettings BooleanFormatting(Action<DataTablesBooleanFormatterBuilder> configure) #
Returns: DataTablesSettings

Configures boolean value rendering (Yes/No, badges, or icons) for all boolean cells.

Parameters

configure System.Action{HtmlForgeX.DataTablesBooleanFormatterBuilder} requiredposition: 0
public DataTablesSettings BytesFormatting(Action<DataTablesByteSizeFormatterBuilder> configure) #
Returns: DataTablesSettings

Formats numeric byte counts for specific headers (e.g., "SizeBytes").

Parameters

configure System.Action{HtmlForgeX.DataTablesByteSizeFormatterBuilder} requiredposition: 0
public DataTablesSettings CallbackEvalPolicy(DataTablesCallbackEvalPolicy policy) #
Returns: DataTablesSettings

Controls whether string callback fields (e.g., rowCallback) are revived into JS functions on the client. Default is Off. Prefer KnownSafeOnly in trusted scenarios.

Parameters

policy HtmlForgeX.DataTablesCallbackEvalPolicy requiredposition: 0
public DataTablesSettings Callbacks(Action<DataTablesCallbacks> configure) #
Returns: DataTablesSettings

Sets DataTables callback functions via inline JS function bodies.

Parameters

configure System.Action{HtmlForgeX.DataTablesCallbacks} requiredposition: 0
public DataTablesSettings ColumnFilters(DataTablesColumnFilterPlacement placement = Top) #
Returns: DataTablesSettings

Adds per-column filter inputs and chooses where they are rendered.

Parameters

placement HtmlForgeX.DataTablesColumnFilterPlacement = Top optionalposition: 0
public DataTablesSettings ConstrainToContainer(Boolean enable = true) #
Returns: DataTablesSettings

Wraps the table in a viewport div to confine horizontal overflow to the component. Enabled by default; disable only when embedding in custom scroll regions.

Parameters

enable System.Boolean = true optionalposition: 0
public DataTablesSettings DateTimeFormatting(Action<DataTablesTemporalFormatterBuilder> configure) #
Returns: DataTablesSettings

Alias for DataTablesTemporalFormatterBuilder>) for discoverability when searching for "DateTime".

Parameters

configure System.Action{HtmlForgeX.DataTablesTemporalFormatterBuilder} requiredposition: 0
DefaultOrder 2 overloads
public DataTablesSettings DefaultOrder(Int32 columnIndex, String direction = "asc") #
Returns: DataTablesSettings

Sets the initial sort order for a column.

Parameters

columnIndex System.Int32 requiredposition: 0
Zero-based column index.
direction System.String = "asc" optionalposition: 1
Sort direction: "asc" or "desc".
public DataTablesSettings DefaultOrder(params ValueTuple<Int32, String>[] orders) #
Returns: DataTablesSettings

Sets multiple default sort orders.

Parameters

orders System.ValueTuple{System.Int32,System.String}[] requiredposition: 0
Pairs of column index and direction.
public DataTablesSettings DetailBackground(DataTablesDetailBackgroundStyle style) #
Returns: DataTablesSettings

Controls the background treatment used for responsive child/detail rows.

Parameters

style HtmlForgeX.DataTablesDetailBackgroundStyle requiredposition: 0
public DataTablesSettings DisableResponsive() #
Returns: DataTablesSettings

Disables responsive display support.

public DataTablesSettings Dom(String dom) #
Returns: DataTablesSettings

Sets a raw DataTables DOM layout string (advanced). Prefer DataTablesDomPreset) when possible.

Parameters

dom System.String requiredposition: 0
DOM layout string, e.g., "Bfrtip".
public DataTablesSettings DomPreset(DataTablesDomPreset preset) #
Returns: DataTablesSettings

Applies a friendly DOM layout preset instead of raw DOM strings.

Parameters

preset HtmlForgeX.DataTablesDomPreset requiredposition: 0
public DataTablesSettings DurationFormatting(Action<DataTablesDurationFormatterBuilder> configure) #
Returns: DataTablesSettings

Formats duration values (TimeSpan or strings like "5.3s", "4.1h") for specific headers. Adds data-order so sorting and exports use a stable numeric value.

Parameters

configure System.Action{HtmlForgeX.DataTablesDurationFormatterBuilder} requiredposition: 0
public DataTablesSettings EmptyArraysAs(String placeholder) #
Returns: DataTablesSettings

Alias for String).

Parameters

placeholder System.String requiredposition: 0
public DataTablesSettings EmptyEnumerablesAs(String placeholder) #
Returns: DataTablesSettings

Display a placeholder when enumerable properties are empty (instead of blank). Examples: "—", "N/A", "None". Pass null to revert to blank.

Parameters

placeholder System.String requiredposition: 0
public DataTablesSettings EncodeCellValues(Boolean enable = true) #
Returns: DataTablesSettings

HTML-encodes plain string cell values produced from objects/dictionaries. Disable only when table values intentionally contain trusted HTML markup.

Parameters

enable System.Boolean = true optionalposition: 0
public DataTablesTable End() #
Returns: DataTablesTable

Returns control to the root builder.

public DataTablesSettings EnumFormatting(Action<DataTablesEnumFormatterBuilder> configure) #
Returns: DataTablesSettings

Formats enum values using [Description]/[Display(Name)] attributes or a PascalCase splitter.

Parameters

configure System.Action{HtmlForgeX.DataTablesEnumFormatterBuilder} requiredposition: 0
public DataTablesSettings ExcludeProperties(params String[] propertyNames) #
Returns: DataTablesSettings

Exclude the specified properties/columns by name (case-insensitive).

Parameters

propertyNames System.String[] requiredposition: 0
public DataTablesSettings ExpanderStyle(DataTablesExpanderStyle style) #
Returns: DataTablesSettings

Controls how responsive row expanders are rendered.

Parameters

style HtmlForgeX.DataTablesExpanderStyle requiredposition: 0
Export 2 overloads
public DataTablesSettings Export(Action<DataTablesExportBuilder> configure) #
Returns: DataTablesSettings

Enables export buttons for the provided formats.

Parameters

formats HtmlForgeX.DataTablesExportFormat[] requiredposition: 0
Export formats to include.
Export(System.Action{HtmlForgeX.DataTablesExportBuilder} configure) #

Configures export buttons using the fluent export builder.

Parameters

configure System.Action{HtmlForgeX.DataTablesExportBuilder} required
Action to configure export buttons and options.
public DataTablesSettings ExportExcel(Action<DataTablesExcelExportBuilder> configure) #
Returns: DataTablesSettings

Configures Excel export via a typed builder that generates a safe customize(xlsx) function for the DataTables Buttons Excel export (e.g., sheet name, freeze header, column widths, number formats).

Parameters

configure System.Action{HtmlForgeX.DataTablesExcelExportBuilder} requiredposition: 0
public DataTablesSettings ExportExcelCsvPdfCopyColumns() #
Returns: DataTablesSettings

Adds common export buttons (Excel, CSV, PDF, Copy) and a column visibility menu with polished styling.

public DataTablesSettings ExportExcelCustomize(String jsFunction) #
Returns: DataTablesSettings

Adds a raw JavaScript customize(...) function to the Excel button. Pass the full function body like: function(xlsx){ ... }.

Parameters

jsFunction System.String requiredposition: 0
public DataTablesSettings ExportRawValues(Boolean enable = true) #
Returns: DataTablesSettings

Ensures CSV/Excel/PDF exports use raw values from cells when available (reads data-raw attribute).

Parameters

enable System.Boolean = true optionalposition: 0
public DataTablesSettings FixedColumns(Int32 left = 0, Int32 right = 0) #
Returns: DataTablesSettings

Fixes left and/or right columns in place when scrolling.

Parameters

left System.Int32 = 0 optionalposition: 0
Number of columns to fix on the left.
right System.Int32 = 0 optionalposition: 1
Number of columns to fix on the right.
public DataTablesSettings FixedHeader(Int32 headerOffset = 0, Boolean footer = false) #
Returns: DataTablesSettings

Enables a fixed header with optional offset and footer support.

Parameters

headerOffset System.Int32 = 0 optionalposition: 0
Offset in pixels for the fixed header.
footer System.Boolean = false optionalposition: 1
True to also fix the footer.
public DataTablesSettings Flatten(Action<DataTablesFlattenColumnsBuilder> configure) #
Returns: DataTablesSettings

Configure per-column enumerable formatting using a fluent helper. Example: s.Flatten(c => c.Named("Inventory").JoinProperty("ComputerName").Separator(", ").MaxItems(5));

Parameters

configure System.Action{HtmlForgeX.DataTablesFlattenColumnsBuilder} requiredposition: 0
public DataTablesSettings FlattenEnumerables(DataTablesEnumerableFormat mode, String joinProperty = null, String separator = ", ", Nullable<Int32> maxItems = null) #
Returns: DataTablesSettings

Flattens enumerable values (e.g., List, array) into strings for both HTML and JavaScript render modes.

Parameters

mode HtmlForgeX.DataTablesEnumerableFormat requiredposition: 0
Flattening strategy (Count, JoinToString, JoinProperty, Json).
joinProperty System.String = null optionalposition: 1
When using JoinProperty, the property name to take from each item.
separator System.String = ", " optionalposition: 2
Separator used for joins (default ", ").
maxItems System.Nullable{System.Int32} = null optionalposition: 3
Optional maximum items to show before appending an overflow indicator.
public DataTablesSettings FlattenProperty(String propertyName, DataTablesEnumerableFormat mode, String joinProperty = null, String separator = ", ", Nullable<Int32> maxItems = null) #
Returns: DataTablesSettings

Applies a property-specific flattening rule for enumerable values.

Parameters

propertyName System.String requiredposition: 0
mode HtmlForgeX.DataTablesEnumerableFormat requiredposition: 1
joinProperty System.String = null optionalposition: 2
separator System.String = ", " optionalposition: 3
maxItems System.Nullable{System.Int32} = null optionalposition: 4
public DataTablesSettings FooterFilters() #
Returns: DataTablesSettings

Adds a footer filter row with inputs for per-column searching.

public DataTablesSettings GeoGroup(String groupId) #
Returns: DataTablesSettings

Assigns a selection group id for cross-component geo selection sync (Leaflet/Globe/VectorMap/DataTables). Use different values when multiple dashboards exist on the same page.

Parameters

groupId System.String requiredposition: 0
GeoLinkFromGlobe 2 overloads
public DataTablesSettings GeoLinkFromGlobe(GlobeGl globe, String keyColumnHeader, Action<DataTablesGeoLinkFromOptions> configure = null) #
Returns: DataTablesSettings

Links globe marker clicks back to the DataTables table by filtering the key column. Requires the globe marker to have a matching Key(...).

Parameters

globeId System.String requiredposition: 0
keyColumnHeader System.String requiredposition: 1
configure System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} = null optionalposition: 2
GeoLinkFromGlobe(HtmlForgeX.GlobeGl globe, System.String keyColumnHeader, System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} configure) #

Links globe marker clicks back to the DataTables table by filtering the key column.

Parameters

globe HtmlForgeX.GlobeGl required
keyColumnHeader System.String required
configure System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} required
GeoLinkFromLeafletMap 2 overloads
public DataTablesSettings GeoLinkFromLeafletMap(LeafletMap map, String keyColumnHeader, Action<DataTablesGeoLinkFromOptions> configure = null) #
Returns: DataTablesSettings

Links Leaflet marker clicks back to the DataTables table by filtering the key column. Requires the Leaflet marker to have a matching Key(...).

Parameters

mapId System.String requiredposition: 0
keyColumnHeader System.String requiredposition: 1
configure System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} = null optionalposition: 2
GeoLinkFromLeafletMap(HtmlForgeX.LeafletMap map, System.String keyColumnHeader, System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} configure) #

Links Leaflet marker clicks back to the DataTables table by filtering the key column.

Parameters

map HtmlForgeX.LeafletMap required
keyColumnHeader System.String required
configure System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} required
GeoLinkFromVectorMapMarkers 2 overloads
public DataTablesSettings GeoLinkFromVectorMapMarkers(JsVectorMap map, String keyColumnHeader, Action<DataTablesGeoLinkFromOptions> configure = null) #
Returns: DataTablesSettings

Links jsVectorMap marker clicks back to the DataTables table by filtering the key column. Requires the vector map marker to have a matching Name (use String)).

Parameters

mapId System.String requiredposition: 0
keyColumnHeader System.String requiredposition: 1
configure System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} = null optionalposition: 2
GeoLinkFromVectorMapMarkers(HtmlForgeX.JsVectorMap map, System.String keyColumnHeader, System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} configure) #

Links jsVectorMap marker clicks back to the DataTables table by filtering the key column.

Parameters

map HtmlForgeX.JsVectorMap required
keyColumnHeader System.String required
configure System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} required
GeoLinkFromVectorMapRegions 2 overloads
public DataTablesSettings GeoLinkFromVectorMapRegions(JsVectorMap map, String keyColumnHeader, Action<DataTablesGeoLinkFromOptions> configure = null) #
Returns: DataTablesSettings

Links jsVectorMap region clicks back to the DataTables table by filtering the key column. Requires your table column to contain region codes matching the dataset (e.g., "US").

Parameters

mapId System.String requiredposition: 0
keyColumnHeader System.String requiredposition: 1
configure System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} = null optionalposition: 2
GeoLinkFromVectorMapRegions(HtmlForgeX.JsVectorMap map, System.String keyColumnHeader, System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} configure) #

Links jsVectorMap region clicks back to the DataTables table by filtering the key column.

Parameters

map HtmlForgeX.JsVectorMap required
keyColumnHeader System.String required
configure System.Action{HtmlForgeX.DataTablesGeoLinkFromOptions} required
public DataTablesSettings GeoLinkKeySeparator(String separator) #
Returns: DataTablesSettings

When set, allows geo link key columns to contain multiple keys (e.g. "US West|EU Central|APAC"). The first key is focused and the remaining keys are highlighted (selection sync) when possible.

Parameters

separator System.String requiredposition: 0
GeoLinkToGlobe 2 overloads
public DataTablesSettings GeoLinkToGlobe(GlobeGl globe, String keyColumnHeader, Double altitude = 1.2, Int32 ms = 900) #
Returns: DataTablesSettings

Links DataTables row clicks to a globe marker (by marker key) by moving the globe point-of-view. Requires the globe marker to have a matching Key(...).

Parameters

globeId System.String requiredposition: 0
keyColumnHeader System.String requiredposition: 1
altitude System.Double = 1.2 optionalposition: 2
ms System.Int32 = 900 optionalposition: 3
GeoLinkToGlobe(HtmlForgeX.GlobeGl globe, System.String keyColumnHeader, System.Double altitude, System.Int32 ms) #

Links DataTables row clicks to a globe marker (by marker key).

Parameters

globe HtmlForgeX.GlobeGl required
keyColumnHeader System.String required
altitude System.Double required
ms System.Int32 required
GeoLinkToLeafletMap 2 overloads
public DataTablesSettings GeoLinkToLeafletMap(LeafletMap map, String keyColumnHeader, Boolean openPopup = true, Nullable<Int32> zoom = null) #
Returns: DataTablesSettings

Links DataTables row clicks to a Leaflet map marker (by marker key). Requires the Leaflet marker to have a matching Key(...).

Parameters

mapId System.String requiredposition: 0
keyColumnHeader System.String requiredposition: 1
openPopup System.Boolean = true optionalposition: 2
zoom System.Nullable{System.Int32} = null optionalposition: 3
GeoLinkToLeafletMap(HtmlForgeX.LeafletMap map, System.String keyColumnHeader, System.Boolean openPopup, System.Nullable{System.Int32} zoom) #

Links DataTables row clicks to a Leaflet map marker (by marker key).

Parameters

map HtmlForgeX.LeafletMap required
keyColumnHeader System.String required
openPopup System.Boolean required
zoom System.Nullable{System.Int32} required
GeoLinkToVectorMapMarkers 2 overloads
public DataTablesSettings GeoLinkToVectorMapMarkers(JsVectorMap map, String keyColumnHeader) #
Returns: DataTablesSettings

Links DataTables row clicks to a jsVectorMap marker by marker name. Requires the vector map marker to have a matching Name (use String)).

Parameters

mapId System.String requiredposition: 0
keyColumnHeader System.String requiredposition: 1
GeoLinkToVectorMapMarkers(HtmlForgeX.JsVectorMap map, System.String keyColumnHeader) #

Links DataTables row clicks to a jsVectorMap marker by marker name.

Parameters

map HtmlForgeX.JsVectorMap required
keyColumnHeader System.String required
GeoLinkToVectorMapRegions 2 overloads
public DataTablesSettings GeoLinkToVectorMapRegions(JsVectorMap map, String keyColumnHeader) #
Returns: DataTablesSettings

Links DataTables row clicks to a jsVectorMap region by region code (ISO). Requires your table column to contain region codes matching the dataset (e.g., "US").

Parameters

mapId System.String requiredposition: 0
keyColumnHeader System.String requiredposition: 1
GeoLinkToVectorMapRegions(HtmlForgeX.JsVectorMap map, System.String keyColumnHeader) #

Links DataTables row clicks to a jsVectorMap region by region code (ISO).

Parameters

map HtmlForgeX.JsVectorMap required
keyColumnHeader System.String required
public DataTablesSettings HeaderFilters() #
Returns: DataTablesSettings

Adds a header filter row with inputs for per-column searching.

public DataTablesSettings HeaderNaming(Action<DataTablesHeaderNamingOptions> configure) #
Returns: DataTablesSettings

Configure how property/header names are transformed into display labels. Supports acronyms (e.g., LAPS, DSRM, RBCD) and per-property overrides.

Parameters

configure System.Action{HtmlForgeX.DataTablesHeaderNamingOptions} requiredposition: 0
public DataTablesSettings HideColumns(params String[] headerNames) #
Returns: DataTablesSettings

Hide columns entirely by header/property name. Columns remain in the data but are not visible.

Parameters

headerNames System.String[] requiredposition: 0
public DataTablesSettings Html() #
Returns: DataTablesSettings
EditorBrowsable(2)

Convenience: render via HTML mode.

public DataTablesSettings IncludeProperties(params String[] propertyNames) #
Returns: DataTablesSettings

Include only the specified properties/columns by name (case-insensitive).

Parameters

propertyNames System.String[] requiredposition: 0
public DataTablesSettings JavaScript() #
Returns: DataTablesSettings
EditorBrowsable(2)

Convenience: render via JavaScript mode.

public DataTablesSettings LabelerForProperty(String header, Func<Object, String> label) #
Returns: DataTablesSettings

Registers a labeler for a specific column header. When the table renders an enumerable column with this header, each item will be projected through the labeler instead of using reflection.

Parameters

header System.String requiredposition: 0
label System.Func{System.Object,System.String} requiredposition: 1
public DataTablesSettings LabelerForType<T>(Func<T, String> label) #
Returns: DataTablesSettings

Type Parameters

T

Parameters

label Func<T, String> requiredposition: 0
LabelerForType``1(System.Func{``0,System.String} label) #

Registers a labeler used to derive display text for values of type T. This keeps display extraction AOT-safe and avoids reflection.

Parameters

label System.Func{``0,System.String} required
public DataTablesSettings Language(Action<DataTablesLanguage> configure) #
Returns: DataTablesSettings

Configures localization strings for this table.

Parameters

configure System.Action{HtmlForgeX.DataTablesLanguage} requiredposition: 0
Action to configure DataTablesLanguage.
public DataTablesSettings LazyInit(Boolean enable = true) #
Returns: DataTablesSettings

Defers DataTables initialization until the table becomes visible (e.g., inside inactive tabs/accordions). Useful for large reports with many hidden tables to improve initial load performance.

Parameters

enable System.Boolean = true optionalposition: 0
public DataTablesSettings LinkifyColumns(Action<DataTablesLinkifyBuilder> configure) #
Returns: DataTablesSettings

Linkifies columns that contain URLs or email addresses. Applies per-header using a lightweight formatter.

Parameters

configure System.Action{HtmlForgeX.DataTablesLinkifyBuilder} requiredposition: 0
public DataTablesSettings NullsAs(String placeholder) #
Returns: DataTablesSettings

Displays a placeholder for null values (default blank).

Parameters

placeholder System.String requiredposition: 0
public DataTablesSettings NumberFormatting(Action<DataTablesNumberFormatterBuilder> configure) #
Returns: DataTablesSettings

Formats numeric columns using .NET format strings (e.g., "N0", "P1"). Adds data-order/raw for correct sorting and export.

Parameters

configure System.Action{HtmlForgeX.DataTablesNumberFormatterBuilder} requiredposition: 0
public DataTablesSettings ObjectSummary(Action<DataTablesObjectSummaryOptions> configure) #
Returns: DataTablesSettings

Configure how non-enumerable complex objects are summarized inside table cells. Enabled by default to avoid noisy CLR type names and provide compact key/value views.

Parameters

configure System.Action{HtmlForgeX.DataTablesObjectSummaryOptions} requiredposition: 0
public DataTablesSettings Ordering(Boolean enable = true) #
Returns: DataTablesSettings

Enables or disables column ordering.

Parameters

enable System.Boolean = true optionalposition: 0
True to allow ordering.
public DataTablesSettings PageLengthControl(DataTablesPageLengthPlacement placement = Top) #
Returns: DataTablesSettings

Controls where the native DataTables page-length selector is rendered when HtmlForgeX manages the layout.

Parameters

placement HtmlForgeX.DataTablesPageLengthPlacement = Top optionalposition: 0
public DataTablesSettings PageLengthLabel(DataTablesPageLengthLabelMode mode = Default) #
Returns: DataTablesSettings

Controls how the native DataTables page-length selector is labeled.

Parameters

mode HtmlForgeX.DataTablesPageLengthLabelMode = Default optionalposition: 0
public DataTablesSettings Paging(Int32 pageLength = 10, Int32[] lengthMenu = null) #
Returns: DataTablesSettings

Enables paging and optionally configures page length and available sizes.

Parameters

pageLength System.Int32 = 10 optionalposition: 0
Number of rows shown per page.
lengthMenu System.Int32[] = null optionalposition: 1
Optional collection of selectable page lengths.
public DataTablesSettings PagingControls(DataTablesPagingPlacement placement = Bottom) #
Returns: DataTablesSettings

Controls where native DataTables pagination buttons are rendered when HtmlForgeX manages the layout.

Parameters

placement HtmlForgeX.DataTablesPagingPlacement = Bottom optionalposition: 0
public DataTablesSettings PagingType(DataTablesPagingType type) #
Returns: DataTablesSettings

Sets the paging UI style.

Parameters

type HtmlForgeX.DataTablesPagingType requiredposition: 0
Paging control type.
public DataTablesSettings PreferArrayRowsInJsRendering(Boolean enable = true) #
Returns: DataTablesSettings

Prefer array rows (instead of object rows) when rendering via JavaScript to reduce per-row allocations. Note: if any ColumnHighlighter rule uses DataStore = "JavaScript", object rows are required; this method only applies when not required.

Parameters

enable System.Boolean = true optionalposition: 0
public DataTablesSettings Preset(DataTablesPreset preset) #
Returns: DataTablesSettings

Applies a pre-defined configuration preset.

Parameters

preset HtmlForgeX.DataTablesPreset requiredposition: 0
public DataTablesSettings ProjectionForType<T>(Action<DataTablesProjectionBuilder<T>> build) #
Returns: DataTablesSettings

Type Parameters

T

Parameters

build Action<DataTablesProjectionBuilder<T>> requiredposition: 0
ProjectionForType``1(System.Action{HtmlForgeX.DataTablesProjectionBuilder{``0}} build) #

Registers an ordered projection (list of named getters) used when summarizing complex objects of type T. Keeps object summaries rich in AOT without reflection.

Parameters

build System.Action{HtmlForgeX.DataTablesProjectionBuilder{``0}} required
public DataTablesSettings RelativeTimeFormatting(Action<DataTablesRelativeTimeFormatterBuilder> configure) #
Returns: DataTablesSettings

Formats date/time or duration values as live-updating relative labels (uses hfx-relative-time).

Parameters

configure System.Action{HtmlForgeX.DataTablesRelativeTimeFormatterBuilder} requiredposition: 0
public DataTablesSettings RenderMode(DataTablesRenderMode mode) #
Returns: DataTablesSettings

Specifies how the table should be rendered.

Parameters

mode HtmlForgeX.DataTablesRenderMode requiredposition: 0
Rendering mode.
Responsive 3 overloads
public DataTablesSettings Responsive(Action<DataTablesResponsiveOptions> configure) #
Returns: DataTablesSettings

Enables responsive display support.

Parameters

enable System.Boolean = true requiredposition: 0
True to enable responsive behaviour.
Responsive(HtmlForgeX.DataTablesDetailsMode mode) #

Enables responsive display and selects how details are rendered.

Parameters

mode HtmlForgeX.DataTablesDetailsMode required
Responsive(System.Action{HtmlForgeX.DataTablesResponsiveOptions} configure) #

Configures responsive behaviour with custom options.

Parameters

configure System.Action{HtmlForgeX.DataTablesResponsiveOptions} required
Action to configure responsive options.
public DataTablesSettings ResponsiveHide(params String[] headerNames) #
Returns: DataTablesSettings

Prefer these columns to hide first when Responsive is active (they appear in the details view).

Parameters

headerNames System.String[] requiredposition: 0
public DataTablesSettings ResponsiveInline() #
Returns: DataTablesSettings
EditorBrowsable(2)

Convenience wrapper to enable Responsive with inline details mode.

RowGroup 2 overloads
public DataTablesSettings RowGroup(Nullable<Int32> columnIndex = null) #
Returns: DataTablesSettings

Groups rows by the provided column index.

Parameters

columnIndex System.Nullable{System.Int32} = null optionalposition: 0
Column index to group by.
public DataTablesSettings RowGroup(Int32 columnIndex, Action<DataTablesRowGroup> configure) #
Returns: DataTablesSettings

Groups rows by a column and applies additional row group configuration.

Parameters

columnIndex System.Int32 requiredposition: 0
configure System.Action{HtmlForgeX.DataTablesRowGroup} requiredposition: 1
public DataTablesSettings RowGroupWithCount(Int32 columnIndex, String labelFormat = null) #
Returns: DataTablesSettings

Groups rows by a column and shows a simple group header with the group label and row count.

Parameters

columnIndex System.Int32 requiredposition: 0
Column index to group by.
labelFormat System.String = null optionalposition: 1
Optional format string. Use {group} and {count} placeholders.
public DataTablesSettings Scrolling(String scrollY = null, Boolean scrollX = false, Boolean scrollCollapse = false) #
Returns: DataTablesSettings

Configures scrolling behaviour for large tables.

Parameters

scrollY System.String = null optionalposition: 0
Height of the scrollable region.
scrollX System.Boolean = false optionalposition: 1
True to allow horizontal scrolling.
scrollCollapse System.Boolean = false optionalposition: 2
True to collapse empty space when scrolling.
public DataTablesSettings ScrollXOnly(Boolean scrollCollapse = true) #
Returns: DataTablesSettings

Switches the table to horizontal scroll mode only: disables Responsive and enables ScrollX. Good for legacy layouts; prefer Boolean) for most cases.

Parameters

scrollCollapse System.Boolean = true optionalposition: 0
public DataTablesSettings SearchBuilder(Action<DataTablesSearchBuilder> configure = null) #
Returns: DataTablesSettings

Enables search builder extension.

Parameters

configure System.Action{HtmlForgeX.DataTablesSearchBuilder} = null optionalposition: 0
Optional configuration callback.
public DataTablesSettings SearchDelay(Int32 milliseconds) #
Returns: DataTablesSettings

Adds a delay (in milliseconds) before applying the global search term while typing. Maps to DataTables option searchDelay and can improve responsiveness on very large tables.

Parameters

milliseconds System.Int32 requiredposition: 0
SearchHighlighting 2 overloads
public DataTablesSettings SearchHighlighting(Action<DataTablesSearchHighlighterConfig> configure) #
Returns: DataTablesSettings

Highlights the active search terms directly inside cell text (HTMLExtensions plugin).

Parameters

enable System.Boolean = true requiredposition: 0
SearchHighlighting(System.Action{HtmlForgeX.DataTablesSearchHighlighterConfig} configure) #

Configures search-term highlighting (HTMLExtensions plugin).

Parameters

configure System.Action{HtmlForgeX.DataTablesSearchHighlighterConfig} required
public DataTablesSettings Searching(Boolean enable = true) #
Returns: DataTablesSettings

Toggles the global search box.

Parameters

enable System.Boolean = true optionalposition: 0
True to enable searching; otherwise false.
public DataTablesSettings SearchPanes(Action<DataTablesSearchPanes> configure = null) #
Returns: DataTablesSettings

Enables search panes extension.

Parameters

configure System.Action{HtmlForgeX.DataTablesSearchPanes} = null optionalposition: 0
Optional configuration callback.
public DataTablesSettings Select(String style = "single") #
Returns: DataTablesSettings

Enables row selection with the specified style.

Parameters

style System.String = "single" optionalposition: 0
Selection style such as "single" or "multi".
public DataTablesSettings ServerSide(Action<DataTablesAjax> configure) #
Returns: DataTablesSettings

Enables server-side processing and configures Ajax.

Parameters

configure System.Action{HtmlForgeX.DataTablesAjax} requiredposition: 0
public DataTablesSettings SharedData(String key) #
Returns: DataTablesSettings

Uses a shared dataset identified by key. Automatically switches the table to JavaScript rendering and binds columns by the current header labels.

Parameters

key System.String requiredposition: 0
Shared registry key under window.hfxShared.
public DataTablesSettings SharedFilter(Action<DataTablesSharedFilterBuilder> configure) #
Returns: DataTablesSettings

Adds initial filters for a table that consumes shared data. Call after String).

Parameters

configure System.Action{HtmlForgeX.DataTablesSharedFilterBuilder} requiredposition: 0
public DataTablesSettings StateSave(Boolean enable = true, Nullable<Int32> durationSeconds = null) #
Returns: DataTablesSettings

Persists table state such as paging and ordering.

Parameters

enable System.Boolean = true optionalposition: 0
True to save state.
durationSeconds System.Nullable{System.Int32} = null optionalposition: 1
Optional duration in seconds (-1 to persist indefinitely). If provided, sets DataTables stateDuration.
public DataTablesSettings Surface(TablerSurfaceStyle style) #
Returns: DataTablesSettings

Applies a shared surface treatment to the table viewport shell.

Parameters

style HtmlForgeX.TablerSurfaceStyle requiredposition: 0
public DataTablesSettings TableBackground(DataTablesTableBackgroundStyle style) #
Returns: DataTablesSettings

Controls how strongly the table body/background is surfaced inside the DataTables shell.

Parameters

style HtmlForgeX.DataTablesTableBackgroundStyle requiredposition: 0
public DataTablesSettings TemporalFormatting(Action<DataTablesTemporalFormatterBuilder> configure) #
Returns: DataTablesSettings

Configures how DateTime/DateTimeOffset/TimeSpan values are rendered in table cells. Example: s.TemporalFormatting(t => t.UtcToLocal().DateTime("yyyy-MM-dd HH:mm").TimeSpanLargestUnit()).

Parameters

configure System.Action{HtmlForgeX.DataTablesTemporalFormatterBuilder} requiredposition: 0
public DataTablesSettings ToggleViewButton(String text = "Switch View", ToggleViewMode defaultMode = Responsive, Boolean persist = true) #
Returns: DataTablesSettings

Adds a built-in toggle button that switches between Responsive and ScrollX at runtime.

Parameters

text System.String = "Switch View" optionalposition: 0
defaultMode HtmlForgeX.ToggleViewMode = Responsive optionalposition: 1
persist System.Boolean = true optionalposition: 2
public DataTablesSettings Toolbar(Action<DataTablesToolbarOptions> configure) #
Returns: DataTablesSettings

Configures the top toolbar layout (buttons + search alignment and order).

Parameters

configure System.Action{HtmlForgeX.DataTablesToolbarOptions} requiredposition: 0
public DataTablesSettings TypeHintsByHeader(Action<DataTablesHeaderTypeHintsBuilder> configure) #
Returns: DataTablesSettings

Assigns DataTables column types using header names (no index math required).

Parameters

configure System.Action{HtmlForgeX.DataTablesHeaderTypeHintsBuilder} requiredposition: 0

Properties

public List<IValueTransformer> Transformers { get; } #

Ordered list of value transformers applied to raw cell values before final formatting. Use to unwrap PSObjects or summarize complex values.

public Boolean SummarizeEnumerables { get; set; } #

When true, non-string enumerable values are summarized according to EnumerableSummary.

public EnumerableSummaryMode EnumerableSummary { get; set; } #

Summary strategy for enumerable values (Count, FirstN, JoinStrings).

public Int32 EnumerableFirstN { get; set; } #

Number of items to include in FirstN mode.

public String EnumerableSeparator { get; set; } #

Separator used when joining enumerable items.

public Int32 EnumerableMaxProbe { get; set; } #

Upper bound on items probed when summarizing to avoid expensive enumeration.

public Boolean InlineEnumerableDetails { get; set; } #

If true, appends a compact inline detail with the first N items under the summary text.

public Func<Object, IEnumerable<Object>> EnumerableDetailsProjector { get; set; } #

Optional projector used to render inline details from an enumerable value (defaults to ToString of first N items).