Count number of uniqe cases

  • Thread starter Thread starter SeRene
  • Start date Start date
S

SeRene

Hi, I have a form(frmSearch) which provides a listbox
(lstTables), listing all the tables and queries in my
database. There are five dropdown lists and textboxes for
the selection of fields and the entering of criteria.
I can do a search with this form by selecting the table or
query i want from lstTables and select the field available
in the selected table/query to set a criteria for it and
the generated results will be reflected in another listbox
(lstResults).

Now, i need to provide 2 textboxes, 1 is to reflect the
total number of results generated in lstResults and the
2nd textbox is to count the number of unique records based
on the 1st field and criteria stated.
 
The first text box is simple just push
lstResults.Listcount into it

For the second text box (if I follow), you could build
some SQL (with Group By), create a recordset and push the
recordsetcount into it. Recorset count returns incorrect
value until you rs.MoveLast
 
Hi, I am not that IT-savvy. I cant really understand what
you are trying to say. Would you mind elaborating?
What do you mean by pushing lstResults.Listcount into it?
What is rs.MoveLast?!?!!
 
Back
Top