DirExists Function

Used to determine whether a specific directory exists within the operating system.

NOTE: This function is deprecated in OpenInsight 10.0 and above. Please use the RTI_OS_DIR() function instead.

retval = DirExists(path)

The function has the following parameters:

ParameterDescription
pathThe full path of the directory being tested.
ValueMeaning
-1The path does not exist.
0The path is valid however it is not a directory.
1The path exists.
* Determine if c:\temp exists

 

declare function DirExists

declare subroutine Msg

path = "C:\TEMP"

retval = DirExists(path)

 

begin case

   case retval = 0

     msg(@window,'The path ':path:' exists but is not a directory.')

   case retval = 1

     msg(@window,'The directory ':path:' does exist.')

   case retval = -1

     msg(@window,'The directory ':path:' does not exist.')

end case
  • guides/programming/programmers_reference_manual/direxists.txt
  • Last modified: 2024/10/25 13:35
  • by bshumsky