Description |
The CreateDir function creates a new directory Dir in the current directory.
If the create succeeded, the True is returned, otherwise the error can be obtained using GetLastError.
|
| Related commands | |
Download this web site as a Windows program.
|
|
|
|
Example code : Create a new directory | begin
 // Create a new directory in the current directory
if CreateDir('TestDir')
then ShowMessage('New directory added OK')
else ShowMessage('New directory add failed with error : '+
IntToStr(GetLastError));
end;
| Show full unit code | New directory added OK |
|
|