I am having a problem accessing a mapped drive in ColdFusion. I have \\server\files\sharing
mapped to z:\
. If I run this code, it says the directory exists for the full path but not for the mapped one:
<cfscript>
fullPath = "\\server\files\sharing\reports";
mappedPath = "z:\reports";
WriteOutput("fullPath exists: #DirectoryExists(fullPath)#<br/>"); //YES
WriteOutput("mappedPath exists: #DirectoryExists(mappedPath)#"); //NO
</cfscript>
I have done some Googling and have found a few people with the same problem, but the solution was always to use the full path. Is there a reason ColdFusion wouldn't be able to see or access the mapped drive? And if so, are there any workarounds (maybe a system call to get the full path of the mapped drive)?