I have a form that I use often, but numbering is slow because I go in and number the form, print, go back and put in next number, print, etc. Is there a macro or formula that will automatically update the consecutive numbers when I enter or print??![]()
I have a form that I use often, but numbering is slow because I go in and number the form, print, go back and put in next number, print, etc. Is there a macro or formula that will automatically update the consecutive numbers when I enter or print??![]()
Assuming the number is in A1 of sheet1, this code will do it
![]()
Please Login or Register to view this content.
Hope that helps.
RoyUK
--------
For Excel Tips & Solutions, free examples and tutorials why not check out my web site
Free DataBaseForm example
How do I write code??? I'm just a admin assist, but I really need for this to work.
Please clarify. Are you printing the SAME form multiple times, and you want each copy to have a different number? Or do you print a form one time, and each time you print a different form, you would like the number to incremement by 1?
If you want to learn code you could start by looking at the link below.
If you want to know where to add Roy's code then see link
http://www.contextures.com/xlvba01.html#Workbook
VBA Noob
_________________________________________
![]()
![]()
Credo Elvem ipsum etian vivere
_________________________________________
A message for cross posters
Please remember to wrap code.
Forum Rules
Please add to your signature if you found this link helpful. Excel links !!!
I am printing the same form multiple times, and I want each copy to have a different number. How do I make this happen??
You would need VBA, assuming you are printing Sheet1 & the number is in A1 This example uses the Before_Print event
![]()
Please Login or Register to view this content.
How do I accomplish this Roy?? Is this a macro or something very strange to me? Can you show me an example??
Yes it's code. Goes in ThisWorkbook module. See link for details.
http://www.contextures.com/xlvba01.html#Workbook
To run press the print button
VBA Noob
I need cell D1 to update every time I print or enter, I don't care which, I need for it to read W6090 print then W6091 print,,,,,
DATE MAPSCO W6089
NAME
ADDRESS CITY
JOB # INSTALLER(S) 10-7 10-8
I need cell D1 to update every time I print or enter, I don't care which, I need for it to read W6090 print then W6091 print,,,,,
DATE MAPSCO W6089
NAME
ADDRESS CITY
JOB # INSTALLER(S) 10-7 10-8
Format D1 as "W"0 and set it to the inital value (e.g., 6089).
Insert this code in the ThisWorkbook module, changing to the correct sheet name:
Note that the number will increment before the sheet is printed.![]()
Please Login or Register to view this content.
abchildress,
Please read rules below. Duplicate posts are not permitted
VBA Noob
shg, you could try being a little more helpful to novices like those above, and even me, i can do some nifty tricks in Excel but even this one needs help...
i have a little form, to be filled by hand, 3 copies to a sheet, so we are gonna print them, and cut the page into 3 lil vouchers
Cell G2 will start autonumbering at 1001
Cell G18 could be 1002, or decide a quantity to print (50) and start at say 1050
Cell G34 could be 1003, or as above and start at 1101
I have heard of a method to print, say 20 forms, starting say, 1001, ending 1020 and a text file saves the last number used, so the next print run picks up from there, at 1021
guide us nicely on some of these ideas or queries
Remember, we are not all code or macro gurus like you, thats why we ask![]()
Limoman,
Unfortunately you need to post your question in a new thread, it's against the forum rules to post a question in the thread of another user. If you create your own thread, any advice will be tailored to your situation so you should include a description of what you've done and are trying to do. Also, if you feel that this thread is particularly relevant to what you are trying to do, you can surely include a link to it in your new thread.
If I have helped, Don't forget to add to my reputation (click on the star below the post)
Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
Use code tags when posting your VBA code: [code] Your code here [/code]
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks