DOM Objects
DOM Anchor
DOM Applet
DOM Area
DOM Base
DOM Basefont
DOM Body
DOM Button
DOM Checkbox
DOM Document
DOM Event
DOM FileUpload
DOM Form
DOM Frame
DOM Frameset
DOM Hidden
DOM History
DOM Iframe
DOM Image
DOM Link
DOM Location
DOM Meta
DOM Navigator
DOM Option
DOM Password
DOM Radio
DOM Reset
DOM Screen
DOM Select
DOM Style
DOM Submit
DOM Table
DOM TableData
DOM TableHeader
DOM TableRow
DOM Text
DOM Textarea
DOM Window

TableRow Object

The TableRow object represents an HTML tr element.

The TableRow object's collections, properties, methods and events are described below:

N: Netscape (including Mozilla when N6 or higher), IE: Internet Explorer, W3C: World Wide Web Consortium (Internet Standard)

Collections

Collection Description N IE  W3C
cells[] Returns an array containing each columns in the table row   4 Yes

Properties

Syntax: object.property_name

Property Description N IE  W3C
accesskey Sets or returns the keyboard key to access the table row   5 No
align Sets or returns the horizontal alignment of data within cells of the table row   4 Yes
bgColor Sets or returns the background color for the table row   4 Yes
borderColor Sets or returns the border color of the table row   4 No
ch Sets or returns the alignment character for cells in the table row   6 Yes
chOff Sets or returns the offset of alignment character for cells in the table row   6 Yes
disabled Sets or returns whether or not the table row should be disabled   5.5 No
height Sets or returns the height of the table row   5 No
id Sets or returns the id of the table row (In IE 4 this property is read-only)   4 No
innerHTML Sets or returns the HTML between the start and end tags of the table row   5 No
innerText Sets or returns the text between the start and end tags of the table row   5 No
outerHTML Sets or returns the table row object and its content in HTML   4 No
outerText Sets or returns the text of the table row object   4 No
rowIndex Returns the table row object's position in the rows collection for the table   4 Yes
sectionRowIndex Returns the table rows object's position in the tBody, tHead, or tFoot rows collection   4 Yes
tabIndex Sets or returns the tab order for the table row   5 No
vAlign Sets or returns how cell content are vertically aligned within the table row   4 Yes
width Sets or returns the width of the table row   4 No

Methods

Syntax: object.method_name()

Method Description N IE W3C
blur() Removes focus from the table row   4 No
click() Simulates a mouse-click on the table row   4 No
deleteCell([i]) Deletes a cell in the table row   4 Yes
focus() Sets focus on the table row   5 No
insertCell([i]) Creates a new cell in the table row   4 Yes

Events

Syntax: object.event_name="someJavaScriptCode"

Event Description N IE W3C
onBlur Executes some code when the table row loses focus   4  
onClick Executes some code when the user clicks on the table row   4  
onFocus Executes some code when the table row gets focus   4  
onSelectStart Executes some code when the table row is selected   4