Hi Michael,
The command that you're sending to Windows doesn't make much sense to
me. This is what you have:
1 'STRPCCMD PCCMD('rundll32 Shell32,ShellExec_RunDLL "C:\Window'
61 's\system32\shimgvw.dll,ImageView_Fullscreen" "/Home/SMITHJM/'
121 'pictestB.jpg"') PAUSE(*NO)
Now.. taking that literally (since that's the way Windows is going to
take it) this is what your command says:
a) Run the rundll32 program.
b) Pass "Shell32,ShellExec_RunDLL" as the first parameter.
c) Pass "C:\Windows\system32\shimgvw.dll,ImageView_Fullscreen" as the
second parameter.
d) Pass "/Home/SMITHJM/pictestB.jpg" as the third parameter.
With that in mind... The rundll32 program is a program that loads
windows DLL into memory, and calls a routine inside it. The first
parameter it receives is a string that represents the DLL name, followed
by the routine name, separated by a comma.
So you have 'Shell32,ShellExec_RunDLL", which means you want Windows to
load the Shell32.dll DLL into memory. (A DLL is like an ILE *SRVPGM.)
It then says "Call the routine named ShellExec_RunDLL" (like an ILE
subprocedure) inside the Shell32.dll object.
So far so good. The remainder of the command line "the second and third
parameters" will be passed to that ShellExec_RunDLL routine as a single
parameter.
The ShellExec_RunDLL routine is a version of the ShellExec() API that
has a parameter list that's compatible with RunDLL32. It will try to
execute it as a command (in a shell-aware environment)
So here's the problem...
"C:\Windows\system32\shimgvw.dll,ImageView_Fullscreen" does not
reference either a program (EXE, COM, etc) or a document (where the
shell would find an associated program). SO it has nothing to run.
I wonder if you meant to remove the ShellExec stuff, and run the
shimgvw.dll directly from rundll32?
Or, if you ARE going to use ShellExec, why are you listing a DLL? Why
not simply list the JPG file and let Windows figure out which program to
view it with?
IT makes little sense the way you have it coded.