The system comes with a tool Rundll.exe advanced application

  
First, please do a small experiment (please save the results of the program you are executing):

Click "Start - Program - Ms-Dos" Enter the DOS window, then type "rundll32.exe user.exe, restartWindows", then press the Enter key, then you will see that the machine has been restarted!

course, Rundll functionality than just reboot your machine. In fact, the Rundll, as the name suggests, executes Dll. Its function is to call the Windows dynamic link library in the command line. The difference between Rundll32.exe and Rundll.exe is that the former is calling the 32-bit link library, and then It is applied to the 16-bit link library. Their command format is:

RUNDLL.EXE,,

There are three points to note here:

1.Dll file The name can not contain spaces. For example, the file is located in the c:\\Program Files directory. You should change this path to c:\\Progra~1;

2. The comma between the Dll file name and the Dll entry point cannot be Less, otherwise the program will go wrong and will not give any information!

3. This is the most important point :Rundll not be used to call the return value parameter containing Dll, e.g. Win32API in GetUserName (), GetTextFace () and the like.

In Visual Basic, an instruction shell for executing an external program is provided, in the format:

Shell "command column"

If you can use Shell with Rundll32.exe The instructions will make your VB
program have effects that are difficult or impossible to achieve with other methods: still take the restart as an example. The traditional method requires you to create a module first in the VB
project. Group, then write the declaration of WinAPI, and finally can call in the program. And now only one sentence:

Shell "rundll32.exe user.exe, restartWindows" is done!

In fact, Rundll32.exe in Windows Control Panel and call a variety of system options has a unique advantage.

Command line: rundll32.exe shell32.dll, Control_RunDLL

Function: Display control panel

Command line: rundll32.exe shell32.dll, Control_RunDLL Access.cpl,, 1

Function: Display "Control Panel - Auxiliary Options - Keyboard" option window

Command line: rundll32.exe shell32.dll, Control_RunDLL Access.cpl,, 2

Function: Display the "Control Panel - Auxiliary Options - Sound" option window
Copyright © Windows knowledge All Rights Reserved