Skip to Content
avatar image
Former Member

How to reset record number , when count exist more than 10

reset.jpgDear Experts ,

In Report i want to display month wise record number and group number , when record count exist more than 10 , then i want to reset the record number field from next month onwards .

For Ex Jan month we have 3 records and Feb Month 12 records , so in record number filed i want to display a number from 1 to 15 , Now Count of record no exist more than 10 from a month Jan & Feb , On March record i want to reset a record number and want to display a record number from 1 .

Is there anyway to do this using crystal formula or running total .

Please check attached image and advise .

reset.jpg (167.8 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    May 30, 2017 at 05:13 PM

    Create a New formula in report header:

    Whileprintingrecords;

    numbervar MGroup:=1;

    another formula in Details:

    Whileprintingrecords;

    numbervar MGroup;

    Add comment
    10|10000 characters needed characters exceeded

  • May 29, 2017 at 06:02 PM

    Create a Manual Running total:

    1. Create a formula @ManualRTotal in Details section:

    Whileprintingrecords;

    numbervar MTotal:=Mtotal + 1

    2. Create @ResetMRT formula in Group Header section:

    Whileprintingrecords;

    numbervar MTotal;

    if MTotal >10 then MTotal :=0;

    MTotal

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Vitaly ,

      Its really helpful , Thanks for your quick reply .

      Additionally i want to add a Manual group Number , where group number should change based on Record Number Manual Reset formula.

      Please check attached image and advise . reset1.jpg

      reset1.jpg (169.2 kB)
  • May 30, 2017 at 02:39 PM

    Modify the formula in Group Header Section:

    Whileprintingrecords;

    numbervar MTotal;

    numbervar MGroup;

    if MTotal >10 then (MTotal :=0; MGroup:=MGroup+1);

    MGroup

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Vitaly,

      I want to display only a Max of Manual Group Value in Report when count of record is greater than 10 . else i want to suppress all section of the page and it should be blank . Is there any way to check Max of Manual group value and Manual group record count . So that i can use that formula in suppress condition to hide data .

      Please check image file and advise . ex2.jpgex3.jpgex1.jpg

      ex2.jpg (171.3 kB)
      ex3.jpg (156.5 kB)
      ex1.jpg (160.3 kB)