Search code examples
.netwindows-764-bittiffphotoviewer

How to run Photoviewer.dll in command line


When I run the following code below in a command prompt (as administrator):

"C:\Program Files\Windows Photo Viewer\PhotoViewer.dll" "C:\00012.tif"

it produces error as shown below :

"This file does not have a program associated with it for performing this action. Please install a program or, if one is already installed, create an associated in the Default Programs control panel."

Both .tif and .tiff are associated in the Default programs control panel.

I am trying to call this from a .net windows app.

Any help is appreciated.


Solution

  • rundll32 "C:\Program Files\Windows Photo Viewer\PhotoViewer.dll" "C:\00012.tif"

    For running a dll, there is rundll32.