Guys.. I know that this is so easy but I can't figure it out why List View Display an False text instead of the Data in my Database my Code is this
Private Sub Form_Load()
ListView2.ListI tems.Clear
Call OpenConn
Call OpenRs
rs.Source = "Select * from Employee"
rs.Open
If rs.RecordCount > 0 Then
Do While Not rs.EOF
Set List = ListView2.ListI tems.Add(, , rs![Employee_No])
List = List.SubItems(1 ) = rs![Emp_Fname]
List = List.SubItems(2 ) = rs![Emp_Mname]
List = List.SubItems(3 ) = rs![Emp_Lname]
List = List.SubItems(4 ) = rs![Emp_Age]
List = List.SubItems(5 ) = rs![Emp_department]
rs.MoveNext
Loop
End If
Call CloseRs
Call closeConn
End Sub
I hope somebody will help me to figure it out.. thanks in advance...
Private Sub Form_Load()
ListView2.ListI tems.Clear
Call OpenConn
Call OpenRs
rs.Source = "Select * from Employee"
rs.Open
If rs.RecordCount > 0 Then
Do While Not rs.EOF
Set List = ListView2.ListI tems.Add(, , rs![Employee_No])
List = List.SubItems(1 ) = rs![Emp_Fname]
List = List.SubItems(2 ) = rs![Emp_Mname]
List = List.SubItems(3 ) = rs![Emp_Lname]
List = List.SubItems(4 ) = rs![Emp_Age]
List = List.SubItems(5 ) = rs![Emp_department]
rs.MoveNext
Loop
End If
Call CloseRs
Call closeConn
End Sub
I hope somebody will help me to figure it out.. thanks in advance...
Comment