R
Ron Vecchi
Hello,
I am opening a file like below:
FileStream fs =
File.Open(Server.MapPath("../Data/REFCOD.txt"),FileMode.Open,FileAccess.Writ
e,FileShare.None);
---------------------------------------------------------
I do not want anyone to access the file while it is opened.
---------------------------------------------------------
My question is:
If another request tries to open this file while it is opened will the
request wait untill it can open it and then proceed with its operation or
will an exception be generated?
I'm hopeing that it will wait untill it can open it and then will.
If not is there a way todo so with out generating an exception?
Thanks,
Ron Vecchi
I am opening a file like below:
FileStream fs =
File.Open(Server.MapPath("../Data/REFCOD.txt"),FileMode.Open,FileAccess.Writ
e,FileShare.None);
---------------------------------------------------------
I do not want anyone to access the file while it is opened.
---------------------------------------------------------
My question is:
If another request tries to open this file while it is opened will the
request wait untill it can open it and then proceed with its operation or
will an exception be generated?
I'm hopeing that it will wait untill it can open it and then will.
If not is there a way todo so with out generating an exception?
Thanks,
Ron Vecchi