isDirectory()

The function checks if the specified string is a directory or a file. The function returns 1 if the specified string is a directory and 0 if the specified string is a file.

Synopsis

int isDirectory( string path);

Parameters

Parameter Meaning
path The directory or file path. You can specify an absolute path or a relative path from the PROJ_PATH directory.

Return value

The function returns true if the directory exists and false if it does not. If no parameter is stated the function returns -1.

Error

-

Description

The function checks if the specified string is a directory. If it is a directory 1 will be returned. If the string is a file, 0 will be returned.

Example

  1. main()
    
    
    {
    
    
      int i;
    
    
      string c = "C://Projekte//Proj_3_5_de_en//panels";
    
    
      i = isDirectory(c);
    
    
      DebugN(" -panels- is a directory:", i);
    
    
    }

Assignment

File functions

Availability

CTRL