Example
Here is an example of how you can use the SHELL function:
SHELL('c:\joe\myprog.exe', 'arg1', 'arg2');
This statement executes a program named myprog.exe in the directory c:\joe. There are two arguments, arg1 and arg2, which are passed to the function. To call the DOS command DIR, you would use this code:
CommandProcessor := 'c:\command.com'; // Windows 95 & Windows 98
CommandProcessor := 'c:\windows\system32\cmd.exe'; // Windows 2000 & Windows XP
Comments
Example
Here is an example of how you can use the SHELL function:
SHELL('c:\joe\myprog.exe', 'arg1', 'arg2');
This statement executes a program named myprog.exe in the directory c:\joe. There are two arguments, arg1 and arg2, which are passed to the function. To call the DOS command DIR, you would use this code:
CommandProcessor := 'c:\command.com'; // Windows 95 & Windows 98
CommandProcessor := 'c:\windows\system32\cmd.exe'; // Windows 2000 & Windows XP
Argument := '/c';
DOSCommand := 'dir';
SHELL(CommandProcessor, Argument, DOSCommand);
If it was hard to write, it should be hard to understand."
Name DataType Subtype Length
rtFileSystem Automation
'Microsoft Scripting Runtime'.FileSystemObject
Add these Line:
CREATE( rtFileSystem ) ;
rtFileSystem.CreateFolder( 'C:\Whatyouwant' ) ;
Tip:
Press F5 in Design-Mode to see many Other Direcory/File-Functions