Help Please

  • Thread starter Thread starter Wishmaster2
  • Start date Start date
W

Wishmaster2

Need some help from some expert. I created a simple purchase order form for
my friend. What we are looking for and I really do not know if it is
possible or not, is for the purchase order number to first appear as the # 1
and every time he prints a new work order, the number changes. He wants to
be from 1 to 1000. Is this possible? If it is, can someone show me a
function on how to do this. Any help is greatly appreciated. Thank You Very
Much.
 
Open the VB editor (Alt F11 or similar). Doubleclick the "ThisWorkbook" object. Paste this
little macro in:

Private Sub Workbook_BeforePrint(Cancel As Boolean)
Sheets(1).Range("B4").Value = _
Sheets(1).Range("B4").Value Mod 1000 + 1
End Sub
 
Back
Top