لقد قمت بتغيير جهاز الكمبيوتر فظهر هذا error
Cast from type 'DBNull' to type 'Integer' is not valid.
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.InvalidCastException: Cast from type 'DBNull' to type 'Integer' is not valid.
Source Error:
Line 57: Dim myresult As VoteResult = New VoteResult()Line 58: myresult.votevgood = parametervgood.ValueLine 59: myresult.votegood = parametergood.ValueLine 60: myresult.votebad = parameterbad.ValueLine 61: myresult.total = parametertotal.Value
Source File: C:\Backup\7-5-04\WebApplication4\Classes\Account.vb Line: 59
Stack Trace:
[invalidCastException: Cast from type 'DBNull' to type 'Integer' is not valid.] Microsoft.VisualBasic.CompilerServices.IntegerType.FromObject(Object Value) +819 WebApplication4.Mall.voteDB.voteresult() in C:\Backup\7-5-04\WebApplication4\Classes\Account.vb:59 WebApplication4._Default.myresult() in C:\Backup\7-5-04\WebApplication4\Default.aspx.vb:94 WebApplication4._Default.submit1_Click(Object sender, EventArgs e) in C:\Backup\7-5-04\WebApplication4\Default.aspx.vb:80 System.Web.UI.WebControls.LinkButton.OnClick(EventArgs e) +108 System.Web.UI.WebControls.LinkButton.System.Web.UI.IPostBackEventHandler.RaisePo
stBackEvent(String eventArgument) +57 System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +18 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +138 System.Web.UI.Page.ProcessRequestMain() +1292ارجو المساعده لحل هذه المشكله