Documentation

This is machine translation

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

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

mlreportgen.dom.Document.package

Package: mlreportgen.dom

Add OPC part files to document package

Syntax

partOut = package(docObj,opcPart)

Description

example

partOut = package(docObj,opcPart) adds a file specified by an OPC part object to the OPC package of a document.

Examples

collapse all

This example shows how to use the package method to add special browser processing code. In this example, the processData.js file operates on the data.json file. This example assumes that there are data.json and processData.js files in the current folder.

import mlreportgen.dom.*;
myReport = Document('myDoc','html');

package(myReport,OPCPart('/data/data.json','data.json'));
package(myReport,OPCPart('/js/processData.js','processData.js'))

close(myReport);

Input Arguments

collapse all

Document OPC package to add files to, specified as an mlreportgen.dom.Document object.

Define an OPCPart object to specify the files to add.

Output Arguments

collapse all

Added OPC part file, represented by an mlreportgen.dom.OPCPart object.

Introduced in R2014b

Was this topic helpful?