Server Error in '/' Application.

Could not find a part of the path 'D:\inetpub\webs\thexgatescom\article\124\The-Nagas-of-Kashmir'.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.IO.DirectoryNotFoundException: Could not find a part of the path 'D:\inetpub\webs\thexgatescom\article\124\The-Nagas-of-Kashmir'.

Source Error:


Line 195:            fpath = "~/doc/art_CH.txt";
Line 196:
Line 197:        StreamReader sr = File.OpenText(Server.MapPath(fpath));
Line 198:        txtCondizioni.Text = sr.ReadToEnd();
Line 199:        sr.Close();

Source File: D:\inetpub\webs\thexgatescom\controls\commerce\compra.ascx.cs    Line: 197

Stack Trace:


[DirectoryNotFoundException: Could not find a part of the path 'D:\inetpub\webs\thexgatescom\article\124\The-Nagas-of-Kashmir'.]
   System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +373
   System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) +738
   System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) +68
   System.IO.StreamReader..ctor(String path, Encoding encoding, Boolean detectEncodingFromByteOrderMarks, Int32 bufferSize, Boolean checkHost) +104
   System.IO.StreamReader..ctor(String path) +34
   System.IO.File.OpenText(String path) +37
   Controls_compra.LoadCondizioni(String ln) in D:\inetpub\webs\thexgatescom\controls\commerce\compra.ascx.cs:197
   Controls_compra.Page_Load(Object sender, EventArgs e) in D:\inetpub\webs\thexgatescom\controls\commerce\compra.ascx.cs:179
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +85
   System.Web.UI.Control.OnLoad(EventArgs e) +79
   System.Web.UI.Control.LoadRecursive() +130
   System.Web.UI.Control.LoadRecursive() +200
   System.Web.UI.Control.LoadRecursive() +200
   System.Web.UI.Control.LoadRecursive() +200
   System.Web.UI.Control.LoadRecursive() +200
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2850


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.4690.0