Intersoft WebGrid Documentation
SelectedObject
Send comments on this topic.
Intersoft WebGrid > Client-side References > SelectedObject

Glossary Item Box

 SelectedObject Properties

tblName Description
Returns the table name of the selected object.

ValueType
string

Default Value
-
gridId Description
Gets the ID of the WebGrid.

ValueType
string

Default Value
-
element Description
Returns the HTML element of the selected object. This method will return a TR object if selection mode is set to Row. Otherwise it will return TD object.

ValueType
object (HTML element)

Default Value
-
rowIndex Description
Returns the index of the selected row.

ValueType
integer

Default Value
-
cellIndex Description
Returns the index of the selected cell. Only available when selection mode is Cell.

ValueType
integer

Default Value
-
type Description
Returns the type of the selected object. Valid type is either Row or Cell.

ValueType
string

Default Value
-

 SelectedObject Methods

GetRowElement Description
Gets the row HTML element of the selected object.

Parameters

Remarks
readonly

Return Value
object

Samples
The sample shows how to access GetRowElement using selected object.

//get grid object
var grid = ISGetObject("WebGrid1");

// get grid get row element using GetSelectedObject.
var rowElm = grid.GetSelectedObject().GetRowElement()
GetRowObject Description
Gets the row object of the selected object.

Parameters

Remarks
readonly

Return Value
object

Samples
The sample shows how to get row object using selected object.
//get grid object
var grid = ISGetObject("WebGrid1");

//get row object of the grid
var rowObj = grid.GetSelectedObject().GetRowObject()
GetColSetRowElement Description
Gets the root/first row of column set rows.

Parameters

Remarks
readonly

Return Value
object
GetColSetRowsElement Description
Gets the columnset rows of selected row.

Parameters

Remarks
readonly

Return Value
array
©2012 Intersoft Solutions Corp. All Rights Reserved.