Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Lance W. Grimes
 
Posts: n/a
Default Incrementing Cell Numbers

All:

I have created an excel "Workorder" form for our employees to write in what
machine they are working on, what parts they used, and how long they spent
on the repair...

The problem... I need to print out hundreds of these forms for the men to
use, and each copy of the form needs to have an unique number.

Is there a way to program a cell to automatically increment by 1 every time
it is printed? Again, I need to print hundreds at a time, and I need them
to automatically increment by 1.

TIA,
Lance


  #2   Report Post  
Jason Morin
 
Posts: n/a
Default

Place this in ThisWorkbook module:

Private Sub Workbook_BeforePrint(Cancel As Boolean)
With Sheets("Sheet1")
.[A1].Value = .[A1].Value + 1
End With
End Sub

---
HTH
Jason
Atlanta, GA


-----Original Message-----
All:

I have created an excel "Workorder" form for our

employees to write in what
machine they are working on, what parts they used, and

how long they spent
on the repair...

The problem... I need to print out hundreds of these

forms for the men to
use, and each copy of the form needs to have an unique

number.

Is there a way to program a cell to automatically

increment by 1 every time
it is printed? Again, I need to print hundreds at a

time, and I need them
to automatically increment by 1.

TIA,
Lance


.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to create a variable column in cell reference Sampson Excel Worksheet Functions 3 February 21st 05 10:13 PM
create a cell that accumulates, numbers from another cell... sombull Excel Discussion (Misc queries) 1 February 18th 05 04:45 PM
How can I write in a text in a cell using numbers and the letters. Sandy Excel Discussion (Misc queries) 2 January 10th 05 11:49 PM
CAN I ADD NUMBERS IN ONE CELL jim1022 Excel Worksheet Functions 2 December 20th 04 10:15 PM
16 DIGIT NUMBERS IN CELL WITHOUT LAST DIGIT BEING A ZERO jnkell Excel Worksheet Functions 2 December 18th 04 07:13 PM


All times are GMT +1. The time now is 07:40 AM.

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

About Us

"It's about Microsoft Excel"