English

How To: Create a directory using the System.Execute() instruction

Summary

The System.Execute() command allows system level calls. On the DOS platform,
system calls are a part of the Command.Com

Procedure

Paste the following single line into a new or existing script.

Code:
System.Execute("c:\command.com /c mkdir c:\temp")

The following code prompts you to enter the new directory into a dialog box.

Code:
newDir=MsgBox.Input("Type in new directory","Create Directory", "")
System.Execute("c:\command.com /c mkdir" ++ newDir)


Note:
Make sure the whole path already exists for the last subdirectory before you create the new directory. For example, if you type in "C:\mydata\maps\parcels", then the directory "C:\mydata\maps" must already exist. All other operating system directory naming rules are still apply.