Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to generate an ID on the moment of printing

Status
Not open for further replies.

Kweker

Programmer
Feb 4, 2002
12
NL
Is it possible that on the moment you give the order to print a certain report in one way or the other a ID is generated and put in a table?
 
I beleive you want to create a unique ID number for the report being created.

One way is to create a table with only one field and one record. Set that field value to the begining number. On the Report open event call that table via a recordset read the number increment by one. Update the table field and use that number with in the report.

Just one of many approches.

Good Luck
ssecca
 
Thanx ssecca for your reply.
Is it possible to save this number in the table with the other fields where this report is based on.

 
I would not normally recommend that unless there is only one user and never any intention of more than one user. Besides that creating a system parameter table to hold and supply constant values to the application is always a good idea anyway. Once this table is established you will find lots of uses for it. Now don't misunderstand, if you need to save this unique number for later use than by all means store it back into the draw point but I would not use that location to pull the next number.

Having fun with Access, always.
ssecca
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top