LOCAL aFiles[1,5] IF ADIR(aFiles,'C:\TheDir\Path\ToCheck','D') = 0 * The directory does not exist, and there is no conflicting filename * so you want to create it here ELSE IF 'D' $ aFiles[1,5] * The directory exists ELSE * The directory doesn't exist, but there's a file with the same name, * so you can't create a directory with this name ENDIF ENDIF