This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materials including this page, select Japan from the country navigator on the bottom of this page.


Class: mlreportgen.dom.HTML
Package: mlreportgen.dom

Append HTML string to HTML object


htmlObjOut = append(htmlObj,htmlText)
htmlObjOut = append(htmlObj,htmlObjToAppend)


htmlObjOut = append(htmlObj,htmlText) converts HTML string into an HTML object and appends the object to htmlObj.

htmlObjOut = append(htmlObj,htmlObjToAppend) appends the htmlObjToAppend object to htmlObj.

Input Arguments

expand all

HTML object to append content to, specified as an mlreportgen.dom.HTML object.

HTML text, specified as a character vector

Example: '<p><b>Hello</b> <i style="color:green">World</i></p>'

HTML object to append, specified as an mlreportgen.dom.HTML object.

Output Arguments

expand all

HTML content appended to an HTML object, returned as an mlreportgen.dom.HTML object.


expand all

Create an HTML object from HTML text, to use for a Microsoft® Word report.

import mlreportgen.dom.*;
rpt = Document('HTML2WordReport','docx');     
htmlObj = HTML('<p><b>Hello</b> <i style="color:green">World</i></p>');

Append content to the HTML object. Append the HTML object to the document.

append(htmlObj,'<p>This is <u>me</u> speaking</p>');

Generate the report.


Introduced in R2015a

Was this topic helpful?