Avatar of Gayathriadithya
Gayathriadithya

asked on 

RUNDLL32 and STRPCCMD

I want ot open a cash drawer through AS/400.So  iam using this code

            STRPCO     PCTA(*NO)                        
            MONMSG     MSGID(IWS4010)                    
            STRPCCMD   PCCMD('C:\RMS400\CDK') PAUSE(*NO)

this CDK is an EXE file. While running this I am getting a DOS prompt, to avoid this popup can i use RUNDLL32. If yes, how it can be used. what are the parameters i need to send in STRPCCMD.



 
Operating Systems

Avatar of undefined
Last Comment
Gayathriadithya
ASKER CERTIFIED SOLUTION
Avatar of Gary Patterson, CISSP
Gary Patterson, CISSP
Flag of United States of America image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of Member_2_276102
Member_2_276102

Gayathriadithya:

The [ RunDLL32.EXE Shell32.DLL,ShellExec_RunDLL ] shell functions work very well. As always with STRPCCMD, the 123-char limit on the command string still must be watched. The alternative RUNRMTCMD can often be more useful than STRPCCMD, particularly when you don't know if the remote system is a Windows PC.

Tom
Tom's right - RUNRMTCMD is a nice solution where you can use it.  It runs as a service on Windows.

When I run a command-window program (as opposed to a Windows program) on Vista Business using

STRPCCMD 'RunDLL32.exe SHELL32.DLL,ShellExec_RunDLL ipconfig.exe') PAUSE(*NO)

I still get the annoying flashing DOS box that pops and quickly disappears.  Using the WSCRIPT technique above, there is no visible artifact shown on the user's screen, plus with the 123 character limit, that long call really eats up your workspace.

Of course, you may see different behavior on other versions of Windows.  Just thought I'd mention my results.

-Gary Patterson

Avatar of Gayathriadithya

ASKER

Thanks for your suggesstion, Excellent solution you have given.
Operating Systems
Operating Systems

Operating systems perform basic tasks, such as recognizing input from the keyboard, sending output to the display screen, keeping track of files and directories on the disk, and controlling peripheral devices such as disk drives and printers. For large systems, the operating system makes sure that different programs and users running at the same time do not interfere with each other. The operating system is also responsible for security, ensuring that unauthorized users do not access the system. Operating systems provide a software platform on top of which other programs, called application programs, can run.

37K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo