Can't determine if a file exists

From: Nikolai Evseev (NikolaiEvseev_at_discussions.microsoft.com)
Date: 08/12/05


Date: Fri, 12 Aug 2005 02:41:01 -0700

Hi there,

I am usign System.IO.File.Exists in my ASP.NET code to determine if a file
exists in the specified location. The webserver is my local machine, which is
a part of the corporate domain. The file the existence of which I am trying
to determine is sitting in the shared folder of the PC which is not a part of
the corporate domain. If the Authenitcation on my webserver allows Anonymous
user to logon then Exists method returns false (I take it happens because my
anonymous user doesn't have access to that shared folder, since it's not a
part of the domain). If I am using windows authentication then everything
works fine, and I am able to see if the file exists in the shared folder. The
last one, though, only works if I open the browser on the same PC where my
webserver is running. But if I am logged on using the same user name and
password on another PC then again Exists method always returns false.
I know it's a little confusing but still hoping that you can help me solving
this problem

Thanks