Topics   All   MacOS (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server   Client   Old   Deprecated   Guides   Examples   Videos
New in version: 12.1   12.2   12.3   12.4   12.5   13.0   13.1   13.2   13.3   13.4    Statistic    FMM    Blog  

Matrix.HTML

Queries html of matrix.

Component Version macOS Windows Linux Server iOS SDK
Matrix 13.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "Matrix.HTML"; MatrixRef { ; firstRow; lastRow; firstCol; lastCol } )   More

Parameters

Parameter Description Example Flags
MatrixRef The matrix reference number. $matrix
firstRow The index of first row.
Default is 0.
0 Optional
lastRow The index of last row.
Default is Matrix.Height-1.
5 Optional
firstCol The index of first column.
Default is 0.
0 Optional
lastCol The index of last column.
Default is Matrix.Width-1.
6 Optional

Result

Returns text or error.

Description

Queries html of matrix.
You can use this method to quickly get all values in a given area as html text to show in a web viewer.
This joins the values and removes text formatting.
Numbers, times and dates are right aligned.

If the matrix has column names, we add them as headers over the html columns.

Examples

Show html in web viewer made from data in Excel:

# load data from Excel document
Set Variable [ $matrix ; Value: MBS( "XL.Sheet.ReadCellsAsMatrix";
$bookRef;
0; // sheet index
0; // first row
9; // last row
0; // first column
5) // last column ]
# now make html
Set Variable [ $html ; Value: MBS( "Matrix.HTML"; $matrix) ]
# and show in web viewer
Set Web Viewer [ Object Name: "web" ; URL: "data:text/html;charset=utf-8," & $html ]

See also

Release notes

Blog Entries

This function checks for a license.

Created 12nd May 2023, last changed 10th August 2023


Matrix.GetValue - Matrix.Height

💬 Ask a question or report a problem