isFileObject

fileOpen(filePath);

This function requires Adobe ColdFusion. Not supported on Lucee, OpenBD, etc.

Argument Reference for the isFileObject function

filePath

Required: Yes
The path to the file you are checking.

Examples sample code invoking the isFileObject function


Tag Syntax

<cfscript> 
 filePath = expandPath("./myfile.txt"); 
 a = fileOpen(filePath); 
 b = fileRead(filePath); 
 writeOutput(isFileObject(a)); 
 writeOutput(isFileObject(b)); 
 writeOutput(getFileInfo(filePath).type); 
 writeOutput(structKeyExists(getFunctionList(), "isFileObject")); 
 </cfscript> 

Fork me on GitHub