How to convert Page Setup Setting (PDF) to JSL Script?Hi Expert,
I'm trying to save my journal report in .pdf through JSL scripting.
My issue now is, I can save the report to fit nicely the landscape page manually using below settings;

But, when I converted the setting to JSL script, it stays in portrait.
Why my script not working? I've set the preferences to landscape as default but still not working
// add the header to the journal
j = Current Journal();
listOfReports = j << child;
nReports = N Items( listOfReports );
// add page breaks
For( i = N Items( listOfReports ), i >= 1, i--,
Insert Into( listOfReports, Page Break Box(), i ));
// make the PDF from the journal
j << set window title ("Daily Analysis Report "||format(today(), "d/m/y",10); );
j << set page setup( {margins( {0.75, 0.75, 0.75, 0.75} ), scale( 0.94 ), portrait(0), paper size( "Letter" )} );
// make the PDF from the journal
j << save PDF("$desktop/reportJSL.pdf");uususing JMP17.0
Automation and ScriptingSharing and Communicating ResultsWindowsRe: How to convert Page Setup Setting (PDF) to JSL Script?Got it.
Somehow, I need to add Wait (0) after set page setup & before save .pdf to make it works.
// add the header to the journal
j = Current Journal();
listOfReports = j << child;
nReports = N Items( listOfReports );
// add page breaks
For( i = N Items( listOfReports ), i >= 1, i--,
Insert Into( listOfReports, Page Break Box(), i ));
// make the PDF from the journal
j << set window title ("Daily Analysis Report "||format(today(), "d/m/y",10); );
j << set page setup( {margins( {0.75, 0.75, 0.75, 0.75} ), scale( 0.94 ), portrait(0), paper size( "Letter" )} );
Wait(0);
// make the PDF from the journal
j << save PDF("$desktop/reportJSL.pdf");
Re: How to convert Page Setup Setting (PDF) to JSL Script?In JMP 18 this didn't work. I had to get rid of the curly braces to make it work:
j << set page setup(Margins( {0.7, 0.2, 0.2, 0.2} ), Scale( 1 ), Portrait( 1 ),Paper Size( "A4" ));