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 17: {
Line 18:     public bool isadmin = false;
Line 19:     int ID = int.Parse(HttpContext.Current.Request["Id"].Replace("#CommentList", ""));
Line 20:     string type = "";
Line 21:     protected void Page_Load(object sender, EventArgs e)

Source File: c:\HostingSpaces\plckarancom\plckaran.com\wwwroot\Usercontrol\Topic\topic_comment.ascx.cs    Line: 19

Stack Trace:


[FormatException: Input string was not in a correct format.]
   System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +13033687
   System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +122
   System.Int32.Parse(String s) +26
   Usercontrol_Comment..ctor() in c:\HostingSpaces\plckarancom\plckaran.com\wwwroot\Usercontrol\Topic\topic_comment.ascx.cs:19
   ASP.usercontrol_topic_topic_comment_ascx..ctor() in c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\3666a4fc\92984c8f\App_Web_40cvjxvm.2.cs:0
   ASP.topicdetail_aspx.__BuildControltopic_comment1() in c:\HostingSpaces\plckarancom\plckaran.com\wwwroot\TopicDetail.aspx:88
   ASP.topicdetail_aspx.__BuildControlContent6(Control __ctrl) in c:\HostingSpaces\plckarancom\plckaran.com\wwwroot\TopicDetail.aspx:15
   System.Web.UI.CompiledTemplateBuilder.InstantiateIn(Control container) +15
   System.Web.UI.MasterPage.InstantiateInContentPlaceHolder(Control contentPlaceHolder, ITemplate template) +90
   ASP.masterpage_master.__BuildControlContentCenter() in c:\HostingSpaces\plckarancom\plckaran.com\wwwroot\MasterPage.master:173
   ASP.masterpage_master.__BuildControlform1() in c:\HostingSpaces\plckarancom\plckaran.com\wwwroot\MasterPage.master:77
   ASP.masterpage_master.__BuildControlTree(masterpage_master __ctrl) in c:\HostingSpaces\plckarancom\plckaran.com\wwwroot\MasterPage.master:1
   ASP.masterpage_master.FrameworkInitialize() in c:\HostingSpaces\plckarancom\plckaran.com\wwwroot\MasterPage.master.cs:912308
   System.Web.UI.UserControl.InitializeAsUserControlInternal() +37
   System.Web.UI.MasterPage.CreateMaster(TemplateControl owner, HttpContext context, VirtualPath masterPageFile, IDictionary contentTemplateCollection) +697
   System.Web.UI.Page.get_Master() +56
   System.Web.UI.Page.ApplyMasterPage() +15
   System.Web.UI.Page.PerformPreInit() +54
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +302


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