Server Error in '/' Application.

Index was outside the bounds of the array.

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.IndexOutOfRangeException: Index was outside the bounds of the array.

Source Error:


Line 69:             db dbFoto = new db();
Line 70:             //Response.Write("select path_foto1 from tab_articoli where id =" + fromSplit[2]); Response.End();
Line 71:             OleDbDataReader drFoto =  dbFoto.ReadDB("select path_foto1 from tab_articoli where id =" + fromSplit[2]);                        
Line 72:             if (drFoto.Read())
Line 73:                 imgFoto.ImageUrl = drFoto["path_foto1"].ToString();

Source File: D:\inetpub\webs\thexgatescom\controls\commerce\userPanel.ascx.cs    Line: 71

Stack Trace:


[IndexOutOfRangeException: Index was outside the bounds of the array.]
   controls_commerce_userPanel.Page_Load(Object sender, EventArgs e) in D:\inetpub\webs\thexgatescom\controls\commerce\userPanel.ascx.cs:71
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +85
   System.Web.UI.Control.OnLoad(EventArgs e) +79
   System.Web.UI.Control.LoadRecursive() +130
   System.Web.UI.Control.LoadRecursive() +200
   System.Web.UI.Control.LoadRecursive() +200
   System.Web.UI.Control.LoadRecursive() +200
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2850


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