In a site, the Unified file system folder for ~/upload sits outside the web root, say root is c:\inetpub\myweb and upload is c:\inetpub\upload_myweb. I need access to a file in the UFS physically (i want to use ADO.NET to read from an excel file), but Server.MapPath gives me c:\inetpub\myweb\upload\myfile when I want to get c:\inetpub\upload_myweb\myfile which is the actual location. Can I do this?
Thanks! I solved this an other way (not as elegant) by checking if the UFS of the file has the CustomProperty PhysicalPath set, and in that case build the physical path from this instead of using Server.MapPath (which is the fallback if the PhysicalPath property is not set).
In a site, the Unified file system folder for ~/upload sits outside the web root, say root is c:\inetpub\myweb and upload is c:\inetpub\upload_myweb. I need access to a file in the UFS physically (i want to use ADO.NET to read from an excel file), but Server.MapPath gives me c:\inetpub\myweb\upload\myfile when I want to get c:\inetpub\upload_myweb\myfile which is the actual location. Can I do this?