Thread: invoice number
View Single Post
  #5  
Old June 7th, 2009, 10:13 PM posted to microsoft.public.access.tablesdbdesign
Douglas J. Steele[_3_]
external usenet poster
 
Posts: 3,143
Default invoice number

Don't think so, Piet.

I don't believe it's possible to change the datatype of a field to
Autonumber if the table already has data.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no private e-mails, please)


"Piet Linden" wrote in message
...
On Jun 7, 3:07 pm, cjgav wrote:
Hi

Thanks for your help i;ve done that ut the problem is the number starts at
1
and I would like to tell it were to start

"bhicks11 via AccessMonster.com" wrote:
One solution might be to base InvoiceNo field on an autonum field. Run
code
to add the autonum (or some variation of it) to the InvoiceNo field
before/when printing the invoice.


Bonnie
http://www.dataplus-svc.com


cjgav wrote:
I would like to add an invoice number to report which is generated only
when
the invoice is printed can anyone explain how to do this please


remove the autonumber (make the field type long integer). Add a
record. Set the value of invoiceNumber to be one less than the one
you want. Change the field type back to autonumber.
Compact the database. And there you go.