Main Content

formatAsHTML

Class: mlreportgen.ppt.ProgressMessage
Namespace: mlreportgen.ppt

Wrap message in HTML tags

Description

example

htmlMessageOut = formatAsHTML(message) returns the message text formatted with HTML tags.

Examples

expand all

This example uses formatAsHTML to display the progress messages.

import mlreportgen.ppt.*;
pre = Presentation('myPresentation.pptx');
     
dispatcher = MessageDispatcher.getTheDispatcher;
l = addlistener(dispatcher,'Message', ...
      @(src, evtdata) disp(evtdata.Message.formatAsHTML));
     
dispatch(dispatcher,ErrorMessage('invalid slide',pre));
open(pre);
     
titleText = Text('This is a Title');
titleText.Style = {Bold};

replace(pre,'Title',titleText);
     
close(pre);
     
delete(l);

Input Arguments

expand all

Progress message, specified as an mlreportgen.ppt.ProgressMessage object.

Output Arguments

expand all

Progress message with HTML tagging, returned as an mlreportgen.ppt.ProgressMessage object.

Version History

Introduced in R2015b