Choose Language Hide Translation Bar
Highlighted
MathStatChem
Level VI

Save Presentation (Save as Powerpoint) Template Setup, Center Graphs in Powerpoint Slide Window

I am working on automating (via JSL) the creation of a powerpoint slide deck, which collects the results of several different reports.  I'm using my corporate powerpoint template, and I've made the first slide in the master slides to be the one I want to use for the slides I create with JMP.  Here is some example JSL that does this.

 

_vc1=Variability Chart(
	Y( :Y ),
	X( :Level1, :Level2 ),
	Model( "Nested" ),
	Std Dev Chart( 0 )
);
r=(_vc1 << Report);
r<<Save Presentation("c:/temp/example1.pptx", Template("C:\temp\corporate_template.pptx"), Outline Titles(None), "PNG");

The frustration I am having is that when I create the presentations, the graphics are always aligned on the top center of the slide.  What I want is the graphic to be centered in the middle of the slide.

 

Here is what I get

MathStatChem_0-1587738450551.png

Here is what I want

MathStatChem_1-1587738473626.png

Currently I have go through each slide and do this manually.  Any suggestions on how to make this happen automatically?  

 

5 REPLIES 5
Highlighted

Re: Save Presentation (Save as Powerpoint) Template Setup, Center Graphs in Powerpoint Slide Window

Is there anything in your corporate template that can be set to achieve the alignment you want?

 

Could you write a Visual Basic macro for PowerPoint?

Learn it once, use it forever!
Highlighted
MathStatChem
Level VI

Re: Save Presentation (Save as Powerpoint) Template Setup, Center Graphs in Powerpoint Slide Window

I could use a macro, but I'd rather no go that step (plus sometimes the save to powerpoint creates more than one graphic image per slide, so that would complicate creating a macro).

 

I would like to know if there is a way to create the template so that it will do what I want.  

Highlighted
txnelson
Super User

Re: Save Presentation (Save as Powerpoint) Template Setup, Center Graphs in Powerpoint Slide Window

When I have had to do what you are requesting, I have created borderless border boxes, placed a spacer box followed by the graph, and then a << get picture of the borderbox, and saved it to my journal.  Then when the pptx gets it, the graph ends up centered

Jim
Highlighted
Nickkkkz666
Level I

Re: Save Presentation (Save as Powerpoint) Template Setup, Center Graphs in Powerpoint Slide Window

I also have came across this problem, and I set the title to . , though this way can not perfectly,but it can move this picture to middle, if you dont like this ., you can cover it, , you can give it a try~~~ let me if any。
Highlighted
David_Burnham
Super User

Re: Save Presentation (Save as Powerpoint) Template Setup, Center Graphs in Powerpoint Slide Window

I've not had much success with JMP functionality for saving presentations so I take a manual approach.  A PPTX file is just a zip file.  And from JSL you can read and write to zip files using the ZIP ARCHIVE object.  So basically I will have a PPTX file with a slide that acts as my template - it might contain an image in the centre of the slide with drop shadows etc.  That image is contained within the zip file - all I need to do is replace that image file with one that I have created based on saving the JMP report content as an image.

 

-Dave
Article Labels

    There are no labels assigned to this post.