0

I've developed a .net service and is up and running. In the code I have to fetch some command and one of them could be to open an image fullscreen (or, in Windows 10, in presentation mode).

I already have my method and is working with other commands (like open notepad, or google chrome, etc)

Private Sub LaunchCommand(filename As String, arguments As String)
    Dim startInfo As New ProcessStartInfo
    startInfo.FileName = filename
    startInfo.Arguments = arguments
    Process.Start(startInfo)
End Sub

What kind of arguments should i pass to that method?

With cmd I can only run

start "" /max "c:\path to my img\img.jpg"

IMPORTANT: I've already setted up permission and other OS stuff. I Just need to open the image.

Emilien
  • 19
  • 4
Jack
  • 489
  • 1
  • 6
  • 18
  • Probably the service, that runs with a service account, must somehow [interact with the currently logged on user account and its Desktop](https://stackoverflow.com/q/4237225/107625). – Uwe Keim Aug 22 '19 at 12:40
  • @UweKeim as i write: I've already setted up permission and other OS stuff. Other commands are working – Jack Aug 22 '19 at 12:42
  • So it seems this is a question for Super User which can be reduced to "_How to show an image full screen from command line_", and has nothing to do with services at all. – Uwe Keim Aug 22 '19 at 12:43
  • Why not [launch Google Chrome in full screen](https://superuser.com/questions/430862/launch-google-chrome-in-fullscreen-mode), passing the image as the "URL"? – Uwe Keim Aug 22 '19 at 12:44
  • @UweKeim aready googled _"How to show an image full screen from command line"_ but nothing useful appears – Jack Aug 22 '19 at 12:45
  • @UweKeim while i was writing it i though about it. If im not going to find a different way I'll do it – Jack Aug 22 '19 at 12:46
  • 1
    The Widows viewers are applets, launched by rundll32.exe. For example, Windows 7 PhotoViewer can be started in full screen with `Dim startInfo As New ProcessStartInfo startInfo.FileName = "C:\Windows\System32\rundll32.exe" startInfo.Arguments = $"{ChrW(34)}C:\Program Files (x86)\Windows Photo Viewer\PhotoViewer.dll{ChrW(34)}, ImageView_Fullscreen {fileName}" Process.Start(startInfo)`. Where `{fileName}` is the full path of the file to open. Better enclose it in quotation marks. – Jimi Aug 22 '19 at 21:17

0 Answers0