Wait till Bound Query is Finished loaded.

  • Thread starter Thread starter Jim Paroski
  • Start date Start date
J

Jim Paroski

I have a Access 2002 adp Form bound to a SQL Query. Is there any way I can
check and do a wait loop untill all records are loaded before continuing.

Thanks.
 
Hello Jim:
You wrote in conference microsoft.public.access.adp.sqlserver on Mon, 1 Mar
2004 13:58:12 -0600:

JP> I have a Access 2002 adp Form bound to a SQL Query. Is there any way I
JP> can check and do a wait loop untill all records are loaded before
JP> continuing.

The following will work:

Dim WithEvents rs As Recordset

Private Sub Form_Open(Cancel As Integer)
Set rs = Recordset
End Sub


Private Sub rs_FetchComplete(ByVal pError As ADODB.Error, adStatus As
ADODB.EventStatusEnum, ByVal pRecordset As ADODB.Recordset)
If adStatus = adStatusOK Then MsgBox "Ready"
End Sub


Vadim
 
Thanks for the quick reply unfortunately this does not work since I am
loading the recordsource on the fly from a command_btn after opening the
form. Like:
Me.InputParameters = "'" + [Forms]![job Entry]![Account] + "'"
Me.RecordSource = "dbo.JOBNUMSEARCHFORM"
(Need to wait for finish loading here)
Any Suggestions
Thanks
 
Hello Jim:
You wrote in conference microsoft.public.access.adp.sqlserver on Tue, 2 Mar
2004 12:00:08 -0600:

JP> Thanks for the quick reply unfortunately this does not work since I am
JP> loading the recordsource on the fly from a command_btn after opening
JP> the form. Like:
JP> Me.InputParameters = "'" + [Forms]![job Entry]![Account] + "'"
JP> Me.RecordSource = "dbo.JOBNUMSEARCHFORM"
JP> (Need to wait for finish loading here)

so what prevents from assigning rs = recordset after you set the
recordsource?

Vadim
 
Back
Top