[This is preliminary documentation and subject to change.]
The HTML Table Formatter component automatically converts data from an ADO Recordset object into an HTML-formatted table.
Note This component is not officially supported by Microsoft Corporation. Peer support is available on the Active Server Pages mailing list or on the microsoft.public.inetserver.iis.activeserverpages newsgroup.
To subscribe to the Active Server Pages mailing list, send mail to listserv@listserv.msn.com with
subscribe ActiveServerPages [firstname lastname]
in the body of the message, and then follow the directions carefully. (firstname and lastname are optional.)
You can reach the newsgroup through msnews.microsoft.com and other NNTP servers.
File Names
HTMLTable.class | The HTML Table Formatter component. |
Set oVar = Server.CreateObject("IISSample.HTMLTable")
None.
Borders | Specifies whether the table cells have borders. |
Caption | Specifies a caption for the table. |
CaptionStyle | Specifies a style for the table's caption. |
HeadingRow | Specifies whether the first row contains column headers. |
AutoFormat | Converts specified ADO Recordset data into an HTML table. |
The following example uses the HTML Table Formatter component to format the data contained in an ADO Recordset object. Note that the first three lines use the Database Access component to extract a set of records from the ADOSamples
database.
<% Set Conn = Server.CreateObject("ADODB.Connection") Conn.Open "ADOSamples" Set RS = Conn.Execute("SELECT * FROM Orders") Set myHTMLTable = Server.CreateObject("IISSample.HTMLTable") myHTMLTable.Borders = True 'True is the default myHTMLTable.HeadingRow = True 'True is the default myHTMLTable.AutoFormat(RS) %>