“/”应用程序中的服务器错误。

索引超出范围。必须为非负值并小于集合大小。
参数名: index

说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.ArgumentOutOfRangeException: 索引超出范围。必须为非负值并小于集合大小。
参数名: index

源错误:


行 30:             bNewsInfo.BrowseAdd(id);
行 31:             //int id = Convert.ToInt32(Request.QueryString["id"]);
行 32:             title.Text = bNewsInfo.GetNewsInfoListByNewsID(id)[0].Title;
行 33:             title1 = bNewsInfo.GetNewsInfoListByNewsID(id)[0].Title;
行 34:             //author.Text= bNewsInfo.GetNewsInfoListByNewsID(id)[0].Author;

源文件: e:\cipNewsNEW\cipNews\Web\cipnews\news_content.aspx.cs    行: 32

堆栈跟踪:


[ArgumentOutOfRangeException: 索引超出范围。必须为非负值并小于集合大小。
参数名: index]
   System.ThrowHelper.ThrowArgumentOutOfRangeException() +78
   System.Collections.Generic.List`1.get_Item(Int32 index) +53
   cipnews_news_content.Page_Load(Object sender, EventArgs e) in e:\cipNewsNEW\cipNews\Web\cipnews\news_content.aspx.cs:32
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +25
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +42
   System.Web.UI.Control.OnLoad(EventArgs e) +132
   System.Web.UI.Control.LoadRecursive() +66
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2428


版本信息: Microsoft .NET Framework 版本:2.0.50727.8745; ASP.NET 版本:2.0.50727.8745