Returns an IHTMLElementCollection object that represents the number of rows in a table.
expression.rows
expression Required. An expression that returns one of the above objects.
rows property as it applies to the FPHTMLTextAreaElement and IHTMLTextAreaElement objects.
Sets or returns a Long that represents the height in number of rows of a TEXTAREA element, which corresponds to the value of the rows attribute.
expression.rows
expression Required. An expression that returns one of the above objects.
rows property as it applies to the FPHTMLFrameSetSite and IHTMLFrameSetElement objects.
Sets or returns a String that represents the number and height of horizontal frames in a FRAMESET element, which corresponds to the value of the rows attribute.
expression.rows
expression Required. An expression that returns one of the above objects.
Remarks
The String value for the rows property can be one or more of the following comma-delimited values:
width | Integer that specifies the frame height, in pixels. |
percentage | Integer, followed by a %. The value is a percentage of total available height. |
* | Integer that specifies the frame height as a relative value. After allocating pixel or percentage values, the remaining space is divided among all relative-sized frames. |
The number of comma-separated items is equal to the number of horizontal frames contained within the FRAMESET, while the value of each item determines the frame height.
Example
As it applies to the FPHTMLFrameSetSite object.
The following example replaces the active document's current HTML with a frameset, and then specifies the number of rows or columns contained in each frameset.
Sub CreateFrameSet()
Dim objFrames As FPHTMLFrameSetSite
ActiveDocument.body.innerHTML = "<frameset id=""topframe"">" & vbCrLf & _
vbTab & "<frame id=""top"">" & vbCrLf & _
vbTab & "<frameset id=""mainframe"">" & vbCrLf & _
vbTab & vbTab & "<frame id=""left"">" & vbCrLf & _
vbTab & vbTab & "<frame id=""right"">" & vbCrLf & _
vbTab & "</frameset>" & vbCrLf & _
"</frameset>"
Set objFrames = ActiveDocument.body.all.tags("frameset").Item("topframe")
objFrames.rows = "75,*"
Set objFrames = ActiveDocument.body.all.tags("frameset").Item("mainframe")
objFrames.cols = "145,*"
End Sub
As it applies to the FPHTMLTable object.
The following example replaces the text in the active document with a table and then changes the background color of the second cell of the second row.
Sub SetCellColor()
Dim objTable As FPHTMLTable
ActiveDocument.body.innerHTML = "<table id=""table1"">" & vbCrLf & _
"<tr><td>r1,c1</td><td>r1,c2</td><td>r1,c3</td></tr>" & vbCrLf & _
"<tr><td>r2,c1</td><td>r2,c2</td><td>r2,c3</td></tr>" & vbCrLf & _
"<tr><td>r3,c1</td><td>r3,c2</td><td>r3,c3</td></tr>" & _
vbCrLf & "</table>"
Set objTable = ActiveDocument.body.all.tags("table").Item("table1")
objTable.rows(1).cells(1).bgColor = "#FF00FF"
End Sub