Start Detail Line Counter at 2, but increment each line by 1

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

Guest

I have a report that I need to list the detail records with a numbering
sequence starting at number 2, but incrementing only by 1. Can this be done
using the controlsource property of the text box used to display the number?
 
Create a text box to display the counter, and in the control source of this
box write

=IIf([CurrentRecord]=1,2,1)

So if the current record will be the first one it will start with two, other
wise it will add 1.

The text box RunningSum Property change it to "Over All"
 
Crossh said:
I have a report that I need to list the detail records with a numbering
sequence starting at number 2, but incrementing only by 1. Can this be done
using the controlsource property of the text box used to display the number?


I think you should use a detail counter text box (named
txtDtlCnt) with controls source set to =1, Running Sum set
to Over All and Visible = No.

Then in your number sequence text box, use the expression:
=txtDtlCnt + 1
 
I have a report that I need to list the detail records with a numbering
sequence starting at number 2, but incrementing only by 1. Can this be done
using the controlsource property of the text box used to display the number?

Add an unbound control to the detail section.
Leave it's Control Source blank.
Name it "RowCount"

Code the Detail Print event:

Me.[RowCount] = Nz(Me.[RowCount], 1) + 1
 

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

Back
Top