B
blabla120
Hi NG,
I want to read a xml-file from an asp-page:
// Kategorien aus xml laden
string pathKategorien =
Server.MapPath("./conf/kategorien.xml");
FileStream fs = new FileStream(pathKategorien, FileMode.Open,
FileAccess.Read, FileShare.ReadWrite);
StreamReader sr = new StreamReader( fs );
XmlSerializer s = new XmlSerializer( typeof( Kategorien ) );
_kat = (Kategorien)s.Deserialize( sr );
I get the Exceptio "UnauthorizedAccessException".
But I am sure that the Access rights are properly set, becaus it is no
problem to read a text-File from the same folder:
string pathKategorien = Server.MapPath("./conf/textfile.txt");
So I suppose there must be something special about XML-file concerning
file access rights.
Does anyone have a hint for me?
Thanx, Bernd
I want to read a xml-file from an asp-page:
// Kategorien aus xml laden
string pathKategorien =
Server.MapPath("./conf/kategorien.xml");
FileStream fs = new FileStream(pathKategorien, FileMode.Open,
FileAccess.Read, FileShare.ReadWrite);
StreamReader sr = new StreamReader( fs );
XmlSerializer s = new XmlSerializer( typeof( Kategorien ) );
_kat = (Kategorien)s.Deserialize( sr );
I get the Exceptio "UnauthorizedAccessException".
But I am sure that the Access rights are properly set, becaus it is no
problem to read a text-File from the same folder:
string pathKategorien = Server.MapPath("./conf/textfile.txt");
So I suppose there must be something special about XML-file concerning
file access rights.
Does anyone have a hint for me?
Thanx, Bernd