hi im having errors with listview binding navigation specifically in last >> and first <<
here's my code
Dim inc As Integer
Dim MaxRows As Integer
Dim dr As DataRow
Dim ds As DataSet
Public Sub navigaterecords()
txtMed_ID.Text = ListView1.Items(inc).SubItems(0).Text
txtMed_name.Text = ListView1.Items(inc).SubItems(1).Text
txtfname.Text = ListView1.Items(inc).SubItems(2).Text
txtMname.Text = ListView1.Items(inc).SubItems(3).Text
txtDept_ID.Text = ListView1.Items(inc).SubItems(4).Text
cboxgender.Text = ListView1.Items(inc).SubItems(5).Text
txtDOB.Text = ListView1.Items(inc).SubItems(6).Text
txtMed_Type.Text = ListView1.Items(inc).SubItems(7).Text
End Sub
Private Sub btnFirst_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnFirst.Click
If inc <> 0 Then
inc = 0
navigaterecords()
End If
End Sub
Private Sub btnLast_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnLast.Click
If inc <> MaxRows - 1 Then
inc = MaxRows - 1
navigaterecords()
End If
End Sub
any help i will appreciate! thanks :)
God bless