Server Error in '/' Application.

startIndex cannot be larger than length of string.
Parameter name: startIndex

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.ArgumentOutOfRangeException: startIndex cannot be larger than length of string.
Parameter name: startIndex

Source Error:


Line 342:
Line 343:<meta property="og:title" content="<%=ProductName %>"><meta property="og:url" content="<%=GetNonSecureServer()%><%=GetProductURLWithLang(ProductId, "", LangId) %>">
Line 344:<meta property="og:image" content="<%=GetNonSecureServer()%><%=ProductImg.Substring(1) %>" />
Line 345:<meta property="og:description" content="<%=ProductShortDesc %>" /><meta property="og:type" content="product" />
Line 346:

Source File: c:\eShopKey\ASP.Net\Shops\oroloi\ViewShopProduct.aspx    Line: 344

Stack Trace:


[ArgumentOutOfRangeException: startIndex cannot be larger than length of string.
Parameter name: startIndex]
   System.String.Substring(Int32 startIndex, Int32 length) +291
   ASP.viewshopproduct_aspx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in c:\eShopKey\ASP.Net\Shops\oroloi\ViewShopProduct.aspx:344
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +95
   System.Web.UI.Page.Render(HtmlTextWriter writer) +39
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +132
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +9497


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