How can I embed RTF or HTML DocBlock contents in PDF reports generated from Simulink models using MATLAB Report Generator?

5 次查看(过去 30 天)
I have DocBlocks in my Simulink model with a document type of "RTF" or "HTML". When generating a PDF report from the model using MATLAB Report Generator, the DocBlocks appear as links in the generated document. Is it possible to embed the actual contents of the DocBlocks in the generated report rather than insert links to the corresponding files?
Setting the document type to "Text" is not an option since I would like to be able to include formatted text, tables and possibly images in the documentation. Exporting to a format other than PDF might be acceptable, but I would also like the text in block diagram images to be searchable and I am not sure if this is possible with formats other than PDF.

回答(1 个)

Paul Kinnucan
Paul Kinnucan 2017-2-9
It is not possible to embed the HTML content of a DocBlock in a PDF report.
It is possible to embed the RTF content of a DocBlock in a PDF report, starting in R2014b, using the Documentation component of the Report Explorer.
To do this:
  1. Use the Report Explorer to insert a Documentation component in a Block Loop in your report setup.
  2. Select PDF (from Word template) as your report's output type.
Selecting this output type causes the Report Explorer to generate your report as a Word document containing the RTF DocBlock content and then open and save the Word report as a PDF document.

类别

Help CenterFile Exchange 中查找有关 Simulink Report Generator 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by