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.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.