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 138:        Dim objrecipe As New Recipe
Line 139:
Line 140:        objrecipe.RecipeId = Me.ItemId
Line 141:
Line 142:        totreviews = objratinglst.TotalReviewsForRecipe(Me.ItemId, Me.FilterBy)

Source File: D:\Webroot\td2k8r2-64\tdcpreview.dytelworld.com\ReviewsFor.aspx.vb    Line: 140

Stack Trace:


[FormatException: Input string was not in a correct format.]
   System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +7475735
   System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +119
   System.Int16.Parse(String s, NumberStyles style, NumberFormatInfo info) +39
   System.String.System.IConvertible.ToInt16(IFormatProvider provider) +46
   System.Convert.ToInt16(Object value) +28
   Recipe.LoadRecipeDetails(Int64 RecipeId, String language) +16873
   Recipe.set_RecipeId(Int64 value) +183
   ReviewsFor.ShowReviews() in D:\Webroot\td2k8r2-64\tdcpreview.dytelworld.com\ReviewsFor.aspx.vb:140
   ReviewsFor.Page_Load(Object sender, EventArgs e) in D:\Webroot\td2k8r2-64\tdcpreview.dytelworld.com\ReviewsFor.aspx.vb:129
   System.Web.UI.Control.OnLoad(EventArgs e) +99
   System.Web.UI.Control.LoadRecursive() +50
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627


Version Information: Microsoft .NET Framework Version:2.0.50727.5485; ASP.NET Version:2.0.50727.5491