Server Error in '/' Application.

Could not find file 'C:\websites\futurepoint\horoscope\online-horoscope\sample-horoscope\.rtf'.

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.FileNotFoundException: Could not find file 'C:\websites\futurepoint\horoscope\online-horoscope\sample-horoscope\.rtf'.

Source Error:


Line 24:         //Write the file directly to the HTTP content output stream.
Line 25:         Response.Flush();
Line 26:         Response.WriteFile(FilePath);
Line 27:         Response.End();
Line 28:         

Source File: c:\websites\futurepoint\horoscope\online-horoscope\sample-horoscope.aspx.cs    Line: 26

Stack Trace:


[FileNotFoundException: Could not find file 'C:\websites\futurepoint\horoscope\online-horoscope\sample-horoscope\.rtf'.]
   System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +14584019
   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) +1430
   System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy) +208
   System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share) +87
   System.Web.HttpResponse.WriteFile(String filename, Boolean readIntoMemory) +166
   Horoscope_SampleHoroscope.Page_Load(Object sender, EventArgs e) in c:\websites\futurepoint\horoscope\online-horoscope\sample-horoscope.aspx.cs:26
   System.Web.UI.Control.LoadRecursive() +71
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3178


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