This has to be very simple but I can't get it right and I'm getting frustrated with it. My code for the Next button works fine while using "index1" for lowerlimit and "index2" for the upperlimit and it goes like this :
but I can't get anything to work for the Previous command button so it stops at the lowerlimit and not keep going til the beginning of the file. I don't know if the simplest way to do this is with a For loop or If statement or Do While....
So I am all ears ..
Thanks in advance
Code:
If index1 < index2 Then
index1 = index1 + 1
Else
MsgBox "This is the last record of the data"
End If
So I am all ears ..
Thanks in advance
Comment