The network name cannot be found???

G

Guest

I don't understand why I am receiving this exception?

"The network name cannot be found".

I am accessing a network drive and can use windows explorer to navigate the
tree and open up the file without a problem? I also have verified that the
path is correct.

FileInfo fi = new FileInfo(path);
try
{
FileStream fs = fi.Open(FileMode.Open, FileAccess.Read, FileShare.ReadWrite);
}
catch (Exception ex)
{
msg+="\n"+ "FileName:" + path + " exception:" + ex.Message.ToString() +
ex.StackTrace.ToString();
fileExist=false;
}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top