Newbie Question about MATLAB Report Generator

2 views (last 30 days)
Kevin on 12 Nov 2021
Commented: Kevin on 12 Nov 2021
Hi everyone,
I am learning how to MATLAB Report Generator to generate PDF file. I am following the magic squares example in the documentation.
Once I have the variable "rpt", I have tried to generate PDF file using this command:
Q1: The above command always generates the PDF in the current folder. How do I change the folder?
Q2: If I delete the PDF file and run the above command a second time, it does not generate the PDF file. Is this expected.

Answers (1)

Kevin on 12 Nov 2021
After playing around with my matlab script a bit more, then I realize that my original question doesn not make sense.
It turns out that it is these lines that will create the pdf file (maybe 0 byte).
rpt =[mfilename('fullpath'), '.pdf']);
tp =;
tp.Title = 'Magic Squares';
tp.Subtitle = 'Columns, Rows, Diagonals: All Equal Sums';
tp.Author = 'Albrecht Durer';
Then it is the line that creates the final PDF file
Am I correct?


Find more on MATLAB Report Generator in Help Center and File Exchange




Community Treasure Hunt

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

Start Hunting!