Skip to main content

Notifications

Community site session details

Community site session details

Session Id : DQKxT1LT+znCF2luFnUwXu
Power Automate - Power Automate Desktop
Answered

How to open Windows Photo Viewer

Like (0) ShareShare
ReportReport
Posted on 27 Oct 2021 08:17:44 by 16

Hello,

 

How can I open a file in the windows photo viewer app with Power Automate Desktop?

There's no exe of the app to add to the 'Run application' activity, and trying to run the dll doesn't do anything.

I can fill in the filename in the application path and it will open, but it will also give me the following error: "Can't execute application/open file ..." 

What is the best way to open these types of native apps?

 

Thanks!

 

  • Eveline_RP Profile Picture
    16 on 27 Oct 2021 at 08:47:53
    Re: How to open Windows Photo Viewer

    Thanks! I used the run powershell script activity with your suggestion, that worked!

  • Verified answer
    VJR Profile Picture
    7,635 on 27 Oct 2021 at 08:35:51
    Re: How to open Windows Photo Viewer

    Hi @Eveline_RP 

     

    Try these options

     

    Option 1. 

    Windows Photo Viewer is run by dllhost.exe COM Surrogate. Basically, it does not have it's own exe file, only dll.

    To start Windows Photo Viewer from command line you would have to use

    %SystemRoot%\System32\rundll32.exe "%ProgramFiles%\Windows Photo Viewer\PhotoViewer.dll", ImageView_Fullscreen %1

     

    where %1 is a full path to a file.

     

    Try making use of the "Run DOS command" or the "Write to CMD session" actions of PAD.

     

    Option 2. 

    If you are ok then set the default file associations of image files on your windows to always open with the Windows Photo Viewer.

    Got to the below screen in Windows

    VJR_0-1635323711460.png

     

    Another way to set the default app is to right click the image file ->  Open With -> Choose Windows photo viewer (make sure to check the default box).

     

    Once done, try launching just the image file and see whether it opens up in the windows photo viewer.

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,660 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,999 Most Valuable Professional

Leaderboard
Loading started