web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How to convert PPTX to...
Power Automate
Answered

How to convert PPTX to Image file (or) PPTX to PDF using VB script or other scripts

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

  Requirements:      

            In desktop flow itself I need to convert PPTX file to image or pdf file format. Please help me to solve this problem

I have the same question (0)
  • MichaelAnnis Profile Picture
    5,727 Moderator on at

    In PAD, open the PowerPoint, and then use the UI elements to File -> Print -> Print Slides. After this I believe there is a drop down option for slides per page (1,2,4, 6, pr 8). There is another drop down for with or without notes. Everything should be accessible through windows UI elements, so I would figure out how to do it, and then simply use the desktop recorder to get a good start. 

  • Verified answer
    Highboy Profile Picture
    1,185 Super User 2024 Season 1 on at

    One way to do it is to create a seperate flow with two input variables.
    In my example there are two input variables called pptxdoc and pdfdoc.

    I called the standalone flow pptxtopdf and it contains one call to powershell

    ---------- Paste below into a new flow, create the two input variables and save it----------

    Scripting.RunPowershellScript Script: $'''$powerpnt = New-Object -ComObject PowerPoint.Application
    $doc = \"%PPTXDoc%\"
    $saveaspath = \"%pdfdoc%\"
    $openDoc = $powerpnt.Presentations.Open($doc,[Microsoft.Office.Core.MsoTriState]::msoFalse,[Microsoft.Office.Core.MsoTriState]::msoFalse,[Microsoft.Office.Core.MsoTriState]::msoFalse)
    $openDoc.SaveAs($saveaspath , [Microsoft.Office.Interop.PowerPoint.PpSaveAsFileType]::ppSaveAsPDF,[Microsoft.Office.Core.MsoTriState]::msoFalse)
    $openDoc.Close()
    $powerpnt.Quit()''' ScriptOutput=> PowershellOutput ScriptError=> ScriptError

    ---------- Do NOT paste this line and the text below into pad ----------

    Now you have a way to convert pptx files into pdf by calling the desktop flow you just saved, with two parameters (And you can reuse it in all your scripts, in the future) 

    Highboy_0-1638127278588.png

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Thank you so much.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 523

#2
Valantis Profile Picture

Valantis 318

#3
David_MA Profile Picture

David_MA 235 Super User 2026 Season 1

Last 30 days Overall leaderboard