This is what I'm doing, I want to count all the valid or updated list of person in listview, I have 4 category The updated, Insufficient, Unknown, and moved out All 3 category is ok but not the updated, since I was not be able to put the value "updated" to the Column of status because the list is almost 1250 something. So I just consider that all data with empty value on status is Updated.
How will I search for that.? Since it is empty...
This is my codes to search for all the empty fields, but i have no luck.! I consider any help. Thanks In advance..
ListView1.ListItems.clear
If Text1.Text = "" Then
dbConnection
Set rs = New ADODB.Recordset
sql = "SELECT * FROM lot_owners WHERE Status LIKE '" & IsNull(Text1.Text) & "'"
rs.Open sql, conn, adOpenDynamic, adLockOptimistic
If Not rs.EOF Then
Do Until rs.EOF
Set lst1 = ListView1.ListItems.Add(, , rs!No)
With lst1
.SubItems(1) = rs!HOA_ID
.SubItems(2) = rs!Name
.SubItems(3) = rs!lot_area
.SubItems(4) = rs!Block_Lot_no
.SubItems(5) = rs!House_bldg_no
.SubItems(6) = rs!City
.SubItems(7) = rs!Province
.SubItems(8) = rs!postal_code
.SubItems(9) = rs!Contact
.SubItems(10) = rs!Status
End With
rs.MoveNext
Loop
End If
rs.Close: Set rs = Nothing
End If
Form7.Label7.Caption = ListView1.ListItems.count
How will I search for that.? Since it is empty...
This is my codes to search for all the empty fields, but i have no luck.! I consider any help. Thanks In advance..
ListView1.ListItems.clear
If Text1.Text = "" Then
dbConnection
Set rs = New ADODB.Recordset
sql = "SELECT * FROM lot_owners WHERE Status LIKE '" & IsNull(Text1.Text) & "'"
rs.Open sql, conn, adOpenDynamic, adLockOptimistic
If Not rs.EOF Then
Do Until rs.EOF
Set lst1 = ListView1.ListItems.Add(, , rs!No)
With lst1
.SubItems(1) = rs!HOA_ID
.SubItems(2) = rs!Name
.SubItems(3) = rs!lot_area
.SubItems(4) = rs!Block_Lot_no
.SubItems(5) = rs!House_bldg_no
.SubItems(6) = rs!City
.SubItems(7) = rs!Province
.SubItems(8) = rs!postal_code
.SubItems(9) = rs!Contact
.SubItems(10) = rs!Status
End With
rs.MoveNext
Loop
End If
rs.Close: Set rs = Nothing
End If
Form7.Label7.Caption = ListView1.ListItems.count