I use ADO for database...and part of it I make codes likr this:
VB Code:
Private Sub cmdPrev_Click()
If Not (rst.BOF = True) Then
rst.MovePrevious 'move previous record
fillfields 'fill the controls
End If
Application.ScreenRefresh
End Sub
Private Sub cmdNext_Click()
If Not (rst.EOF = True) Then
rst.MoveNext 'move to next record
fillfields 'fill the controls
End If
Application.ScreenRefresh
End Sub
Why I have to click "Previous" or "Next" twice in order to get the next/previous record..???...how to make it only one click on this button "Previous/Next" to get the next/previous record...please...is there any missed/wrong in my codes...????
Please find my attached file for your review....Beside Next and Previous Button..it also the same thing with "Update Quantity" on "Fill Invoice" tab...and also for "Check Current Stock" on "Update Item" tab...I dont know why..???