The goal is to print a htm/html file via Windows-API
The parameters of
shell_info.lpVerb = "open"; shell_info.lpFile = "C:\Windows\System32\rundll32.exe"; shell_info.lpParameters = "C:\Windows\System32\mshtml.dll ,PrintHTML "C:\Temp\test.html"";
lpParameters are fetched from the registry key
Everything is fine if running the
C:\Windows\system32\rundll32.exe C:\Windows\system32\mshtml.dll ,PrintHTML "C:\Temp\test.html" via cmd. The printing dialog appears.
::ShellExecuteExW need to be called to achieve the same behavior as the cmd?