Introduction to PowerPoint Command Line Tool
Something else here today about DataPoint. Let’s talk about our DataPoint Command Line Tool for Microsoft PowerPoint to generate presentations via a command job. In other words, generate PowerPoint presentations automatically without the PowerPoint user interface.
The DataPoint Command Line Tool or DataPoint Generator is available in the DataPoint Enterprise edition. We still use the PowerPoint user interface to set up a linked DataPoint presentation. But I want to demonstrate to you how can you generate a snapshot presentation via code or commands.
The advantage of using code to generate presentations, is that you can schedule and automate your PowerPoint presentations and statistics. There will be more soon about the scheduling of this. First I need to explain to you what a command line tool is. But first, I explain how you use DataPoint and PowerPoint without the command line tool. You use DataPoint to set up a link to data in e.g. an Excel document or database that you have with your raw data. Then you click the Snapshot button of DataPoint and it create a new report or up-to-date presentation for you. Next week, if you need an update of your presentation, then you open this presentation again (this is a manual action) and you generate a new updated snapshot presentation.
When you have to generate multiple snapshot presentations, or you need to be sure that every day this work is done in batch, then you need something automated. Kind of snapshot automation without all those manual actions of opening presentations and generating and saving snapshots.
The advantages of a command line tool is that you can automate a job by putting one or multiple commands in a batch file or BAT-file. The DataPoint Generator or DataPoint Command Line tool is such a program. It allows you to generate snapshot presentation via code and it has the following advantages:
- Automation; just single click to start a job
- Multiple commands after each other
- Time saver; you cannot do this faster with manual actions
In case you want to know more about snapshot presentations. click here. The output of this command line tool it the same and a manual snapshot generation.
Command Line Tool
We are now going to automate this snapshot generation. Therefor we use the DataPoint Generator tool. This program is located in the DataPoint Program Files folder.
Default location is C:\Program Files (x86)\PresentationPoint\DataPoint Enterprise edition and the program is called DP1xGEN.EXE. For Microsoft PowerPoint 2013, this is called DP15GEN.EXE. For Microsoft PowerPoint 2016, this is DP16GEN.EXE. 15 and 16 are respectively the internal version number of Microsoft PowerPoint that we follow. When you double click the program to exeucte it, you will get this output:
You see the syntax of this command because you did not add parameters to the command. Let open a command prompt which works better. Right click the Windows icon of your menu and choose Command Prompt from the list.
CD "C:\Program Files (x86)\PresentationPoint\DataPoint Enterprise edition"
and hit ENTER. CD is the command to change your current directory. For the next command we type:
DP15GEN.EXE name-of-our-presentation.pptx snapshot.pptx
and hit ENTER again. This will launch the creation of a new snapshot presentation that will be saved here in this folder with the name snapshot.pptx, based on the name-of-our-presentation.pptx document. The output will be something like:
C:\Program Files (x86)\PresentationPoint\DataPoint Enterprise edition>"C:\Program Files (x86)\PresentationPoint\DataPoint Enterprise edition\DP15GEN.exe" "name-of-our-presentation.pptx" "snapshot.pptx"
12/15/2015 11:30:12 AM Deleting output file name-of-our-presentation.pptx.
12/15/2015 11:30:12 AM Calling Microsoft PowerPoint
12/15/2015 11:30:32 AM Presentation C:\Program Files (x86)\PresentationPoint\DataPoint Enterprise edition\snapshot.pptx successfully generated!