Page 1 of 2 12 LastLast
  1.    16 Aug 2015 #1
    Join Date : Aug 2015
    Posts : 16
    Windows 10 Pro x64

    How to start Microsoft Photos from command line?


    Hi!
    In Windows 10 is new app for photos and albums as default picture viewer.
    In Windows 8.1 I used JPEGView, and sometimes Windows Photo Viewer.
    Now I'm customizing Windows and I know how to start Photo Viewer from cmd and created context menu item.
    I want to associate pictures again to JPEGView and have context menu item for Windows 10 Photos, so, how to run Photos from command line?

    Thank you for every help.
    Miro
      My ComputerSystem Spec
  2.    14 Sep 2015 #2
    Join Date : Jan 2015
    UK, Midlands
    Posts : 11,106
    Win 10 Pro (1703)

    Sure you've got the answer by now.. anyway, here's how you can launch the photos app from a cmd prompt
    explorer.exe shell:appsFolder\Microsoft.Windows.Photos_8wekyb3d8bbwe!App
    or
    start ms-photos:
      My ComputerSystem Spec
  3.    14 Sep 2015 #3
    Join Date : Aug 2015
    Posts : 16
    Windows 10 Pro x64
    Thread Starter

    Thank you! Works!

    But how to use "%1" parameter or filename? When I try anything, also not real path, it always opens MyDocuments.

    Miro
      My ComputerSystem Spec
  4.    14 Sep 2015 #4
    Join Date : Jan 2015
    UK, Midlands
    Posts : 11,106
    Win 10 Pro (1703)

    These 'universal' apps aren't characterised like exe's to use params, it seems. So you can launch them from a command line or powershell, for example, but not with a parameter.
      My ComputerSystem Spec
  5.    14 Sep 2015 #5
    Join Date : Aug 2015
    Posts : 16
    Windows 10 Pro x64
    Thread Starter

    So, how it opens image clicked on?
      My ComputerSystem Spec
  6.    14 Sep 2015 #6
    Join Date : Jan 2015
    UK, Midlands
    Posts : 11,106
    Win 10 Pro (1703)

    I think you mean 'How does it open an image when you click on it?' - well, the problem seems to be that these are not well documented from what I've read. So, you can create shortcuts to them (but not in the normal way) - I know of two ways- and 'open with' allows you to freely change the association between a desktop app and photos.

    But if you look at this:
    Click image for larger version. 

Name:	Photos 'association'.jpg 
Views:	3 
Size:	35.5 KB 
ID:	37510
    you will see there is no path to the Photos app as you would expect for a 'desktop' exe.

    It would seem there is a different mechanism in effect.
      My ComputerSystem Spec
  7.    14 Sep 2015 #7
    Join Date : Aug 2015
    Posts : 16
    Windows 10 Pro x64
    Thread Starter

    I can try make it same way like shortcuts to Libraries, Computer, God Mode...
    If it will work I'll reply.
    Miro
      My ComputerSystem Spec
  8.    15 Sep 2015 #8
    Join Date : Jan 2015
    UK, Midlands
    Posts : 11,106
    Win 10 Pro (1703)

    A thought which probably isn't worth the effort of exploring: start with the question- where is the location opened by Photos as default defined? For example, if it were in the registry, one 'might' be able to write a script that has as parameter what you want to open. That parameter is used to overwrite the default location which Photos would open. Then the script launches Photos. (And rewrites the default location to tidy up).

    Even if the location is defined in the registry, overwriting it might not be effective without logging out, in, which would make the whole idea pretty useless! and if it's hard coded, well, no chance.

    Really not worth the effort to explore...!
      My ComputerSystem Spec
  9.    15 Sep 2015 #9
    Join Date : Aug 2015
    Posts : 16
    Windows 10 Pro x64
    Thread Starter

    Yes, registry manipulating script is maybe only one way, I tried written in post before your and nothing helped.
    Sure is that it must to be possible 'cause if it works when are file associations default, then it's not impossible!

    Miro
      My ComputerSystem Spec
  10.    09 Jun 2016 #10

    Good Image Viewer that works from the command line


    The most useful image viewer I found that works from the command line is ArtSage (ArtSage).
      My ComputerSystem Spec

 
Page 1 of 2 12 LastLast


Similar Threads
Thread Forum
Installation & Upgrade PowerShell PackageManagement (OneGet) - Install Apps from Command Line
If you are not familiar with package managers I recommend you read first the short Chocolatey package manager tutorial at our sister site Windows Eight Forums as an introduction to this tutorial: Chocolatey - Install Apps from Command Line. Although...
Tutorials
Windows 10 Photos app - Edits some photos but not others
This is driving me crazy. I have PhotoShop which runs fine under win10 bty BUT I really like the little Photos app for quick editing however. It doesn't work all the time. The app itself never fails to launch but with about half of the pictures...
Software and Apps
Green Line Under Taskbar
I know this has to do with virtual desktops... but it's super obnoxious. Is there a way to get rid of it? I don't really need or want multiple desktops anyway, and it's irritating that it shows a little green bar under every program even when I...
Customization
HTML: What's wrong with this line?
Want to use an image as a link to an image but nothing shows. Paths are correct. There's not even that broken image icon to show that it can't find the images... it just shows nothing. And I know this works cos I did it before but somethings...
Chillout Room
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 10:40.
Find Us
Twitter Facebook Google+ Ten Forums iOS App Ten Forums Android App



Windows 10 Forums