Intersoft WebGrid Documentation
WebGridRow Class
Members  Example  See Also  Send Feedback
ISNet.WebUI.WebGrid Namespace : WebGridRow Class






Represents the data rows that belongs to WebGridTable object. WebGridRow contains numerous properties that allow you to configure rows, cells, table, child table, etc. according to your styles and manipulate the rows on WebGridTable.

Object Model

WebGridRow Class

Syntax

Visual Basic (Declaration) 
<DescriptionAttribute()>
<SerializableAttribute()>
Public Class WebGridRow 
   Inherits ISNet.WebUI.NamedObjectBase
   Implements ISNet.ICopyable, ISNet.IResetable, ISNet.Serialization.BinarySerialization.IBinarySerialize, ISNet.WebUI.INamedObject 
Visual Basic (Usage)Copy Code
Dim instance As WebGridRow
C# 
[DescriptionAttribute()]
[SerializableAttribute()]
public class WebGridRow : ISNet.WebUI.NamedObjectBase, ISNet.ICopyable, ISNet.IResetable, ISNet.Serialization.BinarySerialization.IBinarySerialize, ISNet.WebUI.INamedObject  
Delphi 
public class WebGridRow = class(ISNet.WebUI.NamedObjectBase, ISNet.ICopyable, ISNet.IResetable, ISNet.Serialization.BinarySerialization.IBinarySerialize, ISNet.WebUI.INamedObject)
JScript 
DescriptionAttribute()
SerializableAttribute()
public class WebGridRow extends ISNet.WebUI.NamedObjectBase implements ISNet.ICopyable, ISNet.IResetable, ISNet.Serialization.BinarySerialization.IBinarySerialize, ISNet.WebUI.INamedObject 
Managed Extensions for C++ 
[DescriptionAttribute()]
[SerializableAttribute()]
public __gc class WebGridRow : public ISNet.WebUI.NamedObjectBase, ISNet.ICopyable, ISNet.IResetable, ISNet.Serialization.BinarySerialization.IBinarySerialize, ISNet.WebUI.INamedObject  
C++/CLI 
[DescriptionAttribute()]
[SerializableAttribute()]
public ref class WebGridRow : public ISNet.WebUI.NamedObjectBase, ISNet.ICopyable, ISNet.IResetable, ISNet.Serialization.BinarySerialization.IBinarySerialize, ISNet.WebUI.INamedObject  

Example

The following example shows you how to programmatically display static columns and rows using WebGrid in unbound mode.
C#Copy Code
private void WebGrid1_InitializeLayout(object sender, ISNet.WebUI.WebGrid.LayoutEventArgs e)
{

    //Create the column
    WebGridColumn wcol = new WebGridColumn("ItemName","ItemName");
    wcol.Bound = false;
    WebGrid1.RootTable.Columns.Add(wcol);

    WebGridColumn wcol1 = new WebGridColumn("Discount","Discount");
    wcol1.Bound = false;
    WebGrid1.RootTable.Columns.Add(wcol1);

    WebGridColumn wcol2 = new WebGridColumn("Price","Price");
    wcol2.Bound = false;
    WebGrid1.RootTable.Columns.Add(wcol2);
   
   
    //Fill the data to table (1st row)
    WebGridRow wrow = new WebGridRow();
    WebGridCell wcell = new WebGridCell();
    wcell.Text="Item1";
    wrow.Cells.Add(wcell);
   
    WebGridCell wcell1 = new WebGridCell();
    wcell1.Text="0";
    wrow.Cells.Add(wcell1);

    WebGridCell wcell2 = new WebGridCell();
    wcell2.Text="100";
    wrow.Cells.Add(wcell2);
    WebGrid1.RootTable.Rows.Add(wrow);

    //Fill the data to table (2nd row)
    WebGridRow wrow1 = new WebGridRow();
    WebGridCell wcell3 = new WebGridCell();
    wcell3.Text="Item2";
    wrow1.Cells.Add(wcell3);
   
    WebGridCell wcell4 = new WebGridCell();
    wcell4.Text="5";
    wrow1.Cells.Add(wcell4);

    WebGridCell wcell5 = new WebGridCell();
    wcell5.Text="200";
    wrow1.Cells.Add(wcell5);
    WebGrid1.RootTable.Rows.Add(wrow1); 
}

Remarks

WebGrid.NET Enterprise 5.0 maintain its ability to render more than one rows as one row unit, enabling implementation of key features such as preview row and columnsets. Our unique row rendering engine has been tested to work perfectly with any combinations of both existing and new features, such as editing, filtering, grouping, UI interactions, and more.  

You can use ChildNotExpandable property to make the specified rows will not expand their child rows. Another important property is Cells that can allow you to customize cells appearance. There are 12 levels of styles inheritance in this new version, from Cell's style level, Cell's CssClass then Column's style, Column's CssClas then LayoutSetting's RowStyle and its CssClass. You can also use KeyValue Property to get the value of the field specified in DataKeyField property, and Position Property to get the ordinal position of the row object.

WebGrid.NET v5.0 provides PreviewRow in which you can show expandable preview row, much like in Microsoft Outlook® auto preview mode. You can configure its settings using PreviewRowSettings.

PreviewRow settings is attached per table and can be found in expandable PreviewRowSettings property. Following is list of PreviewRowSettings:

  • DataMember
  • DefaultExpanded
  • Expandable
  • Height
  • Indentation

Note that it is possible to enable previewrow mode along with columnset mode, as well as with other existing features such as grouping, hierarchical and dozens of UI settings' combinations.

Inheritance Hierarchy

System.Object
   ISNet.WebUI.WebUIBaseClass
      ISNet.WebUI.NamedObjectBase
         ISNet.WebUI.WebGrid.WebGridRow

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

©2012 Intersoft Solutions Corp. All Rights Reserved.