• Counter

    Author
    Topic
    #462196

    I want to update my counter (using the caption of a label) on a form when I get to an evan hundred records. I am incrementing a counter for each record processed.

    I’ve done this before but can’t remember the function or where I used it.

    Can someone prod my memory please. ..

    Viewing 0 reply threads
    Author
    Replies
    • #1175486

      I want to update my counter (using the caption of a label) on a form when I get to an evan hundred records. I am incrementing a counter for each record processed.

      I’ve done this before but can’t remember the function or where I used it.

      Can someone prod my memory please. ..

      I’ve tried –
      If mod intCounter 100 then
      me.lblCounter.caption = “Record ” & intcount
      end if

      But it still updates for each loop, not once for every hundred.

      Can anyone see the problem with this line?

      • #1175488

        Change the line

        If mod intCounter 100 then

        to

        If intCounter Mod 100 = 0 Then

        • #1176368

          Change the line

          If mod intCounter 100 then

          to

          If intCounter Mod 100 = 0 Then

          That’s better, Thanks Hans

    Viewing 0 reply threads
    Reply To: Counter

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: