S
sg
I have one form that opens another form to show related records. The 2nd
form has a custom record counter that runs the following code:
With Me.RecordsetClone
.MoveFirst
Me.RecCount = Me.CurrentRecord & " of " & .RecordCount
End With
I got the code from someone here on this forum and it works great as long as
the 2nd form has records in it. I originally ran the code in the oncurrent
event and also tried onload and afterupdate, but still get the same error.
When I debug, it highlights .MoveFirst. I tried taking that out, but then it
highlights Me.RecCount = Me.CurrentRecord & " of " & .RecordCount. From what
I can figure, it doesn't like that it can't find any record, but I don't know
how to fix it. I am using Access 2007.
Thanks in advance for your help.
form has a custom record counter that runs the following code:
With Me.RecordsetClone
.MoveFirst
Me.RecCount = Me.CurrentRecord & " of " & .RecordCount
End With
I got the code from someone here on this forum and it works great as long as
the 2nd form has records in it. I originally ran the code in the oncurrent
event and also tried onload and afterupdate, but still get the same error.
When I debug, it highlights .MoveFirst. I tried taking that out, but then it
highlights Me.RecCount = Me.CurrentRecord & " of " & .RecordCount. From what
I can figure, it doesn't like that it can't find any record, but I don't know
how to fix it. I am using Access 2007.
Thanks in advance for your help.