cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Image to Table JMP extension imports single or batch images as data tables. Useful to extract curves from pictures or convert image data to curve data to use in analyses like Functional Data Explorer. Download and install the extension.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
Tina442
Level II

saving multiple reports into one powerpoint

Hi,

 

I am aware we can export graphs into powerpoint but having to do this one at a time is a bit cumbersome. I have been attempting to use JSL to recognize all my open reports and export it into one single powerpoint with a for loop and the save presentation() function, but it's not working.

 

I think I'm having trouble figuring out the function that would recognize all my open windows/reports. Can someone please help?

1 ACCEPTED SOLUTION

Accepted Solutions
matth1
Level IV

Re: saving multiple reports into one powerpoint

Something like Get Window List( Type( "Reports" ) ); might help? E.g.

 

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dist = dt << Distribution(
	Continuous Distribution( Column( :height ), Process Capability( 0 ) ),
	Continuous Distribution( Column( :weight ), Process Capability( 0 ) )
);
fitxy = dt << Bivariate( Y( :weight ), X( :height ) );
boxp = dt << Graph Builder(
	Size( 528, 448 ),
	Show Control Panel( 0 ),
	Variables( X( :sex ), Y( :height ) ),
	Elements( Box Plot( X, Y, Legend( 4 ) ), Points( X, Y, Legend( 5 ) ) )
);

winlist = Get Window List( Type( "Reports" ) );
Wait( 0 );

For( i = 1, i <= N Items( winlist ), i++,
	pw = New Window( "output", <<Window View( "Invisible" ), winlist[i] << get picture );
	If( i == 1,
		pw << Save Presentation( "$TEMP/all_reports.pptx" ),
		pw << Save Presentation( "$TEMP/all_reports.pptx", Append )
	);
	pw << close window();
);
Open( "$TEMP/all_reports.pptx" );

This saves the exact image of the report. To get the typical output with JMP tables, replace pw with winlist[i] in the << Save Presentation lines and delete the lines with pw.

 

EDIT: the original code left lots of hidden windows called "Output", "Output 2"... sorry. 

 

View solution in original post

2 REPLIES 2
matth1
Level IV

Re: saving multiple reports into one powerpoint

Something like Get Window List( Type( "Reports" ) ); might help? E.g.

 

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dist = dt << Distribution(
	Continuous Distribution( Column( :height ), Process Capability( 0 ) ),
	Continuous Distribution( Column( :weight ), Process Capability( 0 ) )
);
fitxy = dt << Bivariate( Y( :weight ), X( :height ) );
boxp = dt << Graph Builder(
	Size( 528, 448 ),
	Show Control Panel( 0 ),
	Variables( X( :sex ), Y( :height ) ),
	Elements( Box Plot( X, Y, Legend( 4 ) ), Points( X, Y, Legend( 5 ) ) )
);

winlist = Get Window List( Type( "Reports" ) );
Wait( 0 );

For( i = 1, i <= N Items( winlist ), i++,
	pw = New Window( "output", <<Window View( "Invisible" ), winlist[i] << get picture );
	If( i == 1,
		pw << Save Presentation( "$TEMP/all_reports.pptx" ),
		pw << Save Presentation( "$TEMP/all_reports.pptx", Append )
	);
	pw << close window();
);
Open( "$TEMP/all_reports.pptx" );

This saves the exact image of the report. To get the typical output with JMP tables, replace pw with winlist[i] in the << Save Presentation lines and delete the lines with pw.

 

EDIT: the original code left lots of hidden windows called "Output", "Output 2"... sorry. 

 

Tina442
Level II

Re: saving multiple reports into one powerpoint

That's exactly it! Thanks for the solution, this works perfectly :)

Recommended Articles