Server Error in '/' Application.

Attempted to divide by zero.

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.DivideByZeroException: Attempted to divide by zero.

Source Error:


Line 211:            int start = 1;
Line 212:            int end = 0;
Line 213:            int k = recordcount / recordinpage;
Line 214:            //kiem tra co sang trang ko
Line 215:            int div = recordcount % recordinpage;

Source File: c:\www\benhviendkkvhongngu.vn\DesktopModules\NEWS\TT_DSTinTiepTheo.aspx.cs    Line: 213

Stack Trace:


[DivideByZeroException: Attempted to divide by zero.]
   Liink.CMS.TT_dsTinTiepTheo.PhanTrang(Int32 curpage, Int32 recordinpage, Int32 recordcount, Int64 vND_ID) in c:\www\benhviendkkvhongngu.vn\DesktopModules\NEWS\TT_DSTinTiepTheo.aspx.cs:213
   Liink.CMS.TT_dsTinTiepTheo.Page_Load(Object sender, EventArgs e) in c:\www\benhviendkkvhongngu.vn\DesktopModules\NEWS\TT_DSTinTiepTheo.aspx.cs:193
   System.Web.UI.Control.OnLoad(EventArgs e) +107
   System.Web.UI.Control.LoadRecursive() +89
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1532


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