sql and label counting

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a form that on it has a list box (lstClaimNumber) and below it there
is a label (lblClaimCount) to say how many claim numbers there are in the
listbox. Below is the sql statement that is used to fill the listbox. The 2
lines below the sql statement do the counting. Currently, the table has 3381
records in it. I even moved it to an excel sheet to make sure. When an
"All" button is selected, these lines run. But the label will report back
3253 as the number of records. It is 128 difference. I am at a loss as to
why. Can anyone see any error in the lines below?
Thanks to anyone responding.
*** John

Me.lstClaimNumber.RowSource = _
" SELECT " & _
" SurveyResponseID, " & _
" Month, " & _
" Year, " & _
" ClaimNumber " & _
" FROM tblSurveyResponses " & _
" WHERE (((ClaimNumber) > 0)) " & _
" ORDER BY ClaimNumber;"

Me.lstClaimNumber = Me.lstClaimNumber.ItemData(0)
Me.lblClaimCount.Caption = lstClaimNumber.ListCount & " total surveys"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top