simulink_root does not have a parameter named 'PaperType'
23 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Peman
am 24 Sep. 2025 um 16:56
Kommentiert: Peman
am 26 Sep. 2025 um 16:25
My code is using the following to set the paper type for Simulink. Howerver, I am getting the following error: simulink_root does not have a parameter named 'PaperType'.
set_param(0,'PaperType','A4'); % Simulink
Note: A similar command is used on the line before to set the paper type for MATLAB and that one works (see below). Also the same code runs on R2011b but it fails on R2025b after conversion.
set(0,'DefaultFigurePaperType','a4'); % Matlab
5 Kommentare
Walter Roberson
am 26 Sep. 2025 um 1:17
By the way, for set_param(0,'PaperType','A4')
R2018a reported
Warning: Clearing the current default model template so that new models will inherit this property of the root block diagram. To restore the default
model template call Simulink.defaultModelTemplate('$restore') or restart MATLAB. For more information, see the documentation.
Akzeptierte Antwort
Walter Roberson
am 26 Sep. 2025 um 1:40
R2022b reports
Warning: Getting parameter 'PaperType' of the default block diagram will not be supported in a future release.
Warning: Setting parameter 'PaperType' of the default block diagram will not be supported in a future release because new models inherit parameter values from templates.
Warning: Clearing the current default model template so that new models will inherit this property of the root block diagram. To restore the default model template call Simulink.defaultModelTemplate('$restore') or restart MATLAB. For more information, see the
documentation.
By R2023b, the facility was gone.
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Model, Block, and Port Callbacks finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!