A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

invoice number on a report



 
 
Thread Tools Display Modes
  #1  
Old November 21st, 2005, 04:02 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default invoice number on a report

I need to create an invoice report that has an auto-populated invoice # on
the first page of each group of data, where each first page has the next
sequential invoice number. And I need it to use the next sequential #, each
time the report is ran - is this possible???


Thank you.
  #2  
Old November 22nd, 2005, 12:30 AM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default invoice number on a report

It is possible to store the highest number used so far in a table, use
DLookup() to read the value in the Report Header section, and add a text box
to the Detail (or Invoice header?) section and give it these properties:
Control Source =1
Running Sum Over All
Format General Number
Name txtCount
Visible No

Then add another text box that sums the two values:
=[txtLastUsed] + [txtCount]

I could not recommend that approach though. People pay on invoice numbers,
and your database is not storing them. Later you will have no way to trace
what Invoice 54 was, who it was to, which items it contains, or even when it
was printed. If a user filters or sorts the records differently in the
report, the database is not reliable, not ot mention the problem of keeping
the stored value up to date.

In general, you need a routine that creates and stores the invoices as a
batch, so the numbers are meaningful and you can refer to any invoice or
print it again later.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"afg" wrote in message
news
I need to create an invoice report that has an auto-populated invoice # on
the first page of each group of data, where each first page has the next
sequential invoice number. And I need it to use the next sequential #,
each
time the report is ran - is this possible???


Thank you.


  #3  
Old November 22nd, 2005, 12:54 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default invoice number on a report

Thanks Allen! That's exactly what I needed to know.

"Allen Browne" wrote:

It is possible to store the highest number used so far in a table, use
DLookup() to read the value in the Report Header section, and add a text box
to the Detail (or Invoice header?) section and give it these properties:
Control Source =1
Running Sum Over All
Format General Number
Name txtCount
Visible No

Then add another text box that sums the two values:
=[txtLastUsed] + [txtCount]

I could not recommend that approach though. People pay on invoice numbers,
and your database is not storing them. Later you will have no way to trace
what Invoice 54 was, who it was to, which items it contains, or even when it
was printed. If a user filters or sorts the records differently in the
report, the database is not reliable, not ot mention the problem of keeping
the stored value up to date.

In general, you need a routine that creates and stores the invoices as a
batch, so the numbers are meaningful and you can refer to any invoice or
print it again later.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"afg" wrote in message
news
I need to create an invoice report that has an auto-populated invoice # on
the first page of each group of data, where each first page has the next
sequential invoice number. And I need it to use the next sequential #,
each
time the report is ran - is this possible???


Thank you.




 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Reporting subreport total on main report BobV Setting Up & Running Reports 22 November 1st, 2005 03:19 AM
Help to append flat file table to two tables Victoriya F via AccessMonster.com Running & Setting Up Queries 11 September 26th, 2005 05:30 PM
Number of objects thomak General Discussion 3 February 17th, 2005 11:58 AM
incorrect sums in report using 2 tables jkendrick75 Setting Up & Running Reports 22 December 13th, 2004 02:19 PM
Add Invoice Autonumber to Report, Break Out Clients Karl Burrows General Discussion 6 June 7th, 2004 01:37 AM


All times are GMT +1. The time now is 11:49 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.