igGrid
Namespace: Wisej.Web.Ext.Ignite
Assembly: Wisej.Web.Ext.Ignite (4.1.0.0)
The igGrid control is a jQuery grid that includes user interaction features like filtering, grouping, column hiding and resizing, paging, row and cell selection.
- C#
- VB.NET
public class igGrid : igBase
Public Class igGrid
Inherits igBase
Constructors
igGrid()
Constructs a new instance of the igGrid class.
Example:
The following example creates a grid, binds it to a list of objects and lets the grid generate the columns.
var grid = new igGrid();
grid.Options.dataSource = customers;
grid.Options.primaryKey = "Id";
grid.Options.autoGenerateColumns = true;
grid.Dock = DockStyle.Fill;
this.Controls.Add(grid);
igGrid(options)
Constructs a new instance of the igGrid class using the specified options.
| Name | Type | Description |
|---|---|---|
| options | Object | Initial set of options passed to the igGrid widget: an anonymous object, a JSON string or a dynamic object. |
Example:
The following example creates a grid with predefined columns and enables the paging and sorting features.
var grid = new igGrid(new
{
dataSource = customers,
primaryKey = "Id",
autoGenerateColumns = false,
columns = new[]
{
new { key = "Id", headerText = "Id", dataType = "number" },
new { key = "Name", headerText = "Customer", dataType = "string" },
new { key = "Country", headerText = "Country", dataType = "string" }
},
features = new object[]
{
new { name = "Paging", pageSize = 20 },
new { name = "Sorting" }
}
});
grid.Dock = DockStyle.Fill;
this.Controls.Add(grid);