I just upgraded to VB6. I am using the VB application wizard to create a form that uses an ADO control. The wizard goes through the process fine but when I try and run the application, I get an error. The error is on this line of code:

Private Sub datPrimaryRS_MoveComplete(ByVal adReason As
ADODB.EventReasonEnum, ByVal pError As ADODB.Error, adStatus As ADODB.EventStatusEnum, ByVal pRecordset As ADODB.Recordset)
'This will display the current record position for this recordset
datPrimaryRS.Caption = "Record: " & CStr(datPrimaryRS.Recordset.AbsolutePosition)
End Sub

When I click run right after this was created I get an error message stating:

Compile Error. User-Defined type not defined.


P.S. the above line of code was written by the VB apoplication.


Any Ideas??????