Multiple-step operation generated errors!!!!!!!!!
Visual Basic 6 SP5
ADO 2.6.
SQL Server 2000
I try to handel all errors that generated by ADO when user update Recordset.
I do the following to samiulate data entry mistaks:
Public Sub TestADO
rst(0) = "TEST" ' rst(0) is a Long field
rst.Update
Exit Sub
ErrorHandel:
If Connection.Errors.Count = 0 Then
Debug.Print "Error: " & Err.Description
Else
Dim objErr As ADODB.Error
For Each objErr In Connection.Errors
Debug.Print objErr.Description
Next
End If
End Sub
I got this error : Multiple-step operation generated errors. Check each status
value.
I expact another error message liek "The value you entered is not consistent
with the data type or length of the column."
Also I got the same error message (Multiple-step operation generated errors.
Check each status value.) when I try to samiulate any error.
How can solve such a problem?
Thnaks in Advance
Re: Multiple-step operation generated errors!!!!!!!!!
"ethar" <ethar1@yahoo.com> wrote:
>
>Visual Basic 6 SP5
>ADO 2.6.
>SQL Server 2000
>I try to handel all errors that generated by ADO when user update Recordset.
>I do the following to samiulate data entry mistaks:
>
>Public Sub TestADO
> rst(0) = "TEST" ' rst(0) is a Long field
> rst.Update
> Exit Sub
>ErrorHandel:
> If Connection.Errors.Count = 0 Then
> Debug.Print "Error: " & Err.Description
> Else
> Dim objErr As ADODB.Error
> For Each objErr In Connection.Errors
> Debug.Print objErr.Description
> Next
> End If
>End Sub
>
>I got this error : Multiple-step operation generated errors. Check each
status
>value.
>I expact another error message liek "The value you entered is not consistent
>with the data type or length of the column."
>
>Also I got the same error message (Multiple-step operation generated errors.
>Check each status value.) when I try to samiulate any error.
>How can solve such a problem?
>Thnaks in Advance
>
>
-------
I have received the same error:
I am trying to save a null to a field does not allow null values.
I am trying to update/save a value that is to large for the field.
I had to re-look at my database and make the appropiate changes in the database
i.e. change field to accept null(s) or increase field length.
You can write code to handle that specific error if you know the error number
and write a return error message to the user.
Zac