Server Error in '/' Application.

Input string was not in a correct format.

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.FormatException: Input string was not in a correct format.

Source Error:


Line 26:         {
Line 27:             string str = srd.ReadLine();
Line 28:             count = UInt32.Parse(str);
Line 29:         }
Line 30:         srd.Close(); 

Source File: d:\Code\gzdx2016\wssp\JSQ\count.ascx.cs    Line: 28

Stack Trace:


[FormatException: Input string was not in a correct format.]
   System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +426
   System.Number.ParseUInt32(String value, NumberStyles options, NumberFormatInfo numfmt) +226
   System.UInt32.Parse(String s) +78
   JSQ_count.Page_Load(Object sender, EventArgs e) in d:\Code\gzdx2016\wssp\JSQ\count.ascx.cs:28
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +223
   System.Web.UI.Control.OnLoad(EventArgs e) +195
   System.Web.UI.Control.LoadRecursive() +200
   System.Web.UI.Control.LoadRecursive() +356
   System.Web.UI.Control.LoadRecursive() +356
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3954


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