95

In Windows 10, when opening images, it gives me the option to open in the Photos metro app, Paint, or GIMP.

I'd like it to open in Photo Viewer, but when I directed "Open with" to PhotoViewer.dll in "C:/Program Files/Windows Photo Viewer", or "C:/Program Files (x86)/Windows Photo Viewer", I get a "This app can not run on your PC" error.

I know I could use Irfanview or the sort, but I'd prefer to be able to use Photo Viewer. Is there any way I can bring it back?

Irastris
  • 1,111

7 Answers7

80

I think because of your first attempt to run the .dll directly, the entry "Windows Photo Viewer" still points to the .dll instead of rundll32, which of course you can't run directly.

Try adding the following to the registry:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Applications\photoviewer.dll]

[HKEY_CLASSES_ROOT\Applications\photoviewer.dll\shell]

[HKEY_CLASSES_ROOT\Applications\photoviewer.dll\shell\open]
"MuiVerb"="@photoviewer.dll,-3043"

[HKEY_CLASSES_ROOT\Applications\photoviewer.dll\shell\open\command]
@=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,\
00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,72,00,75,00,\
6e,00,64,00,6c,00,6c,00,33,00,32,00,2e,00,65,00,78,00,65,00,20,00,22,00,25,\
00,50,00,72,00,6f,00,67,00,72,00,61,00,6d,00,46,00,69,00,6c,00,65,00,73,00,\
25,00,5c,00,57,00,69,00,6e,00,64,00,6f,00,77,00,73,00,20,00,50,00,68,00,6f,\
00,74,00,6f,00,20,00,56,00,69,00,65,00,77,00,65,00,72,00,5c,00,50,00,68,00,\
6f,00,74,00,6f,00,56,00,69,00,65,00,77,00,65,00,72,00,2e,00,64,00,6c,00,6c,\
00,22,00,2c,00,20,00,49,00,6d,00,61,00,67,00,65,00,56,00,69,00,65,00,77,00,\
5f,00,46,00,75,00,6c,00,6c,00,73,00,63,00,72,00,65,00,65,00,6e,00,20,00,25,\
00,31,00,00,00

[HKEY_CLASSES_ROOT\Applications\photoviewer.dll\shell\open\DropTarget]
"Clsid"="{FFE2A43C-56B9-4bf5-9A79-CC6D4285608A}"

[HKEY_CLASSES_ROOT\Applications\photoviewer.dll\shell\print]

[HKEY_CLASSES_ROOT\Applications\photoviewer.dll\shell\print\command]
@=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,\
00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,72,00,75,00,\
6e,00,64,00,6c,00,6c,00,33,00,32,00,2e,00,65,00,78,00,65,00,20,00,22,00,25,\
00,50,00,72,00,6f,00,67,00,72,00,61,00,6d,00,46,00,69,00,6c,00,65,00,73,00,\
25,00,5c,00,57,00,69,00,6e,00,64,00,6f,00,77,00,73,00,20,00,50,00,68,00,6f,\
00,74,00,6f,00,20,00,56,00,69,00,65,00,77,00,65,00,72,00,5c,00,50,00,68,00,\
6f,00,74,00,6f,00,56,00,69,00,65,00,77,00,65,00,72,00,2e,00,64,00,6c,00,6c,\
00,22,00,2c,00,20,00,49,00,6d,00,61,00,67,00,65,00,56,00,69,00,65,00,77,00,\
5f,00,46,00,75,00,6c,00,6c,00,73,00,63,00,72,00,65,00,65,00,6e,00,20,00,25,\
00,31,00,00,00

[HKEY_CLASSES_ROOT\Applications\photoviewer.dll\shell\print\DropTarget]
"Clsid"="{60fd46de-f830-4894-a628-6fa81bc0190d}"

(Source)

If that doesn't work, try searching the registry for Windows Photo Viewer and photoviewer.dll to see if there are any references to photoviewer.dll being called directly (without rundll32).

25

I got mine to work, I think you have to successfully open an image with the old photo viewer once, then you can set it as default.

  1. Open an image with this in command prompt %SystemRoot%\System32\rundll32.exe "%ProgramFiles%\Windows Photo Viewer\PhotoViewer.dll", ImageView_Fullscreen pathToImageNoQuotes

  2. Then I have this option

enter image description here

Now my PNGs open with the old photo viewer by default, works great.

TechnoCore
  • 2,460
  • 2
  • 20
  • 17
17

Put this in a .reg file and run it:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\jpegfile\shell\open]
"MuiVerb"=hex(2):40,00,25,00,50,00,72,00,6f,00,67,00,72,00,61,00,6d,00,46,00,\
  69,00,6c,00,65,00,73,00,25,00,5c,00,57,00,69,00,6e,00,64,00,6f,00,77,00,73,\
  00,20,00,50,00,68,00,6f,00,74,00,6f,00,20,00,56,00,69,00,65,00,77,00,65,00,\
  72,00,5c,00,70,00,68,00,6f,00,74,00,6f,00,76,00,69,00,65,00,77,00,65,00,72,\
  00,2e,00,64,00,6c,00,6c,00,2c,00,2d,00,33,00,30,00,34,00,33,00,00,00

[HKEY_CLASSES_ROOT\jpegfile\shell\open\command]
@=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,\
  00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,72,00,75,00,\
  6e,00,64,00,6c,00,6c,00,33,00,32,00,2e,00,65,00,78,00,65,00,20,00,22,00,25,\
  00,50,00,72,00,6f,00,67,00,72,00,61,00,6d,00,46,00,69,00,6c,00,65,00,73,00,\
  25,00,5c,00,57,00,69,00,6e,00,64,00,6f,00,77,00,73,00,20,00,50,00,68,00,6f,\
  00,74,00,6f,00,20,00,56,00,69,00,65,00,77,00,65,00,72,00,5c,00,50,00,68,00,\
  6f,00,74,00,6f,00,56,00,69,00,65,00,77,00,65,00,72,00,2e,00,64,00,6c,00,6c,\
  00,22,00,2c,00,20,00,49,00,6d,00,61,00,67,00,65,00,56,00,69,00,65,00,77,00,\
  5f,00,46,00,75,00,6c,00,6c,00,73,00,63,00,72,00,65,00,65,00,6e,00,20,00,25,\
  00,31,00,00,00

This will make all JPEG files viewable in Photo Viewer. If you want to make other types work as well just replace "jpegfile" in the code with "pngfile", "giffile", "Paint.Picture" (Paint.Picture is the .bmp type)

Find any picture, right-click, choose Open With, then find Windows Photo Viewer and select it as default program.

adrift21
  • 179
14

You can also use Winaero Tweaker to activate Windows Photo Viewer, as shown in the following screenshot. Just follow the description (within the green box), and you're all set.

PS: Winaero Tweaker is a free tool, which can be used to tweak many aspects of Windows 10.

Winaero Tweaker - Activate Windows Photo Viewer

5

I have found a solution without having to alter the registry. I have followed TechnoCore's answer, but as the comments indicated, the second part wasn't working for me either. So this is what to do:

  1. Open a command line as administrator
  2. Type in the following:
>ftype MyFileType=%SystemRoot%\System32\rundll32.exe "C:\Program Files\Windows Photo Viewer\PhotoViewer.dll" ImageView_Fullscreen %1
>assoc .jpg=MyFileType
  1. Then go to the image file and choose open with... and then choose the command you just typed: enter image description here

Make sure you have the "Always use this app..." option checked.
Repeat it for all file types you want to associate with Windows Photo Viewer.

ylka
  • 273
2

Unfortunately, none of the above answers worked for me, but they pointed me in the right direction.

  1. Right-click on an image in Windows Explorer, choose Open With, then Choose another app.
  2. In the dialog, scroll down and click on More apps, then `Look for another app on this PC.
  3. Then, at the bottom right, choose All Files (*.*) instead of Programs (*.exe ...), then navigate to C:\Program Files\Windows Photo Viewer and choose PhotoViewer.dll.
  4. Photo Viewer opens. Close it.
  5. Repeat Step 1: Right-click again on the image, choose Open With, then Choose another app.
  6. Again scroll down to click on More apps.
  7. Now Windows Photo Viewer appears in the apps list. Choose it and click on Always use this app to open .png files.

Once you did steps 1-4, you don't have to repeat them for other file types. Steps 5-7 should suffice.

1

I didnt care for the other Registry answers, as they were all encoded. Here is one that is decoded:

Windows Registry Editor Version 5.00

[-HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts.jpg] [HKEY_CLASSES_ROOT\jpegfile\shell\open\command] @="rundll32.exe "C:\Program Files\Windows Photo Viewer\PhotoViewer.dll",ImageView_Fullscreen %1"

[-HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts.png] [HKEY_CLASSES_ROOT\pngfile\shell\open\command] @="rundll32.exe "C:\Program Files\Windows Photo Viewer\PhotoViewer.dll",ImageView_Fullscreen %1"

If your %ProgramFiles% is not C:\Program Files, then adjust as needed.

Zombo
  • 1