isFileObject

fileOpen(filePath);

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

isFileObject Argument Reference

filePath
Required

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