Server Error in '/' Application.

StartIndex cannot be less than zero.
Parameter name: startIndex

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.ArgumentOutOfRangeException: StartIndex cannot be less than zero.
Parameter name: startIndex

Source Error:


Line 60: 
Line 61:                 int lstIndx = col.LastIndexOf("<p>. . .</p>");
Line 62:                 col = col.Remove(lstIndx, 12);
Line 63:                 lblDownloads.Text = col;
Line 64:             }

Source File: d:\ASPX_Sites\HomeShowCenter\DownloadPage.aspx    Line: 62

Stack Trace:


[ArgumentOutOfRangeException: StartIndex cannot be less than zero.
Parameter name: startIndex]
   System.String.Remove(Int32 startIndex, Int32 count) +7099799
   ASP.downloadpage_aspx.Page_Load(Object sender, EventArgs e) in d:\ASPX_Sites\HomeShowCenter\DownloadPage.aspx:62
   System.Web.UI.Control.OnLoad(EventArgs e) +108
   System.Web.UI.Control.LoadRecursive() +90
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1533


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