Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
C&S
 
Posts: n/a
Default How do I print the same sheet multiple times with increasing page.

How do I print the same sheet multiple times with increasing page numbers?
  #2   Report Post  
Peter Rooney
 
Posts: n/a
Default

C&S,

You could try something like this:

Sub MultiPrint()
Dim PrintCount As Integer
For PrintCount = 1 To 5
ActiveSheet.PageSetup.CenterFooter = "Page " & PrintCount
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Next
End Sub

To increase the number of prints, simply change the "5" to whatever value
you require

Hope this helps

Pete


"C&S" wrote:

How do I print the same sheet multiple times with increasing page numbers?

  #3   Report Post  
C&S
 
Posts: n/a
Default

Thank you very much! But where do you type this? Is it a script file? If so,
how do you get excel to run it?

"Peter Rooney" wrote:

C&S,

You could try something like this:

Sub MultiPrint()
Dim PrintCount As Integer
For PrintCount = 1 To 5
ActiveSheet.PageSetup.CenterFooter = "Page " & PrintCount
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Next
End Sub

To increase the number of prints, simply change the "5" to whatever value
you require

Hope this helps

Pete


"C&S" wrote:

How do I print the same sheet multiple times with increasing page numbers?

  #4   Report Post  
C&S
 
Posts: n/a
Default

How do you let the program know that you want to print multiple copies. It
is only printing one. I got it into the visual basic, but the print preview
only shows one copy. Thanks.
  #5   Report Post  
Peter Rooney
 
Posts: n/a
Default

Hi, C&S!

Have you copied the code into a Visual Basic module?

From your worksheet, press Alt+F11

Click "Insert" and "Module" from the menu

Paste the code into the module sheet that is inserted

Press Alt+F11 again to go back to your worksheet

Click on "Tools" "Macro" "Macros" from the menu

Double click "Multiprint" (the macro name from) box that is displayed.

You can only see one copy in Print Preview because it doesn't know about the
code.

Sub MultiPrint()
Dim PrintCount As Integer
For PrintCount = 1 To 5
ActiveSheet.PageSetup.CenterFooter = "Page " & PrintCount
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Next
End Sub

When you run the macro in the manner shown above, you'll get 5 prints, each
one with an incrementing page number. If you change "1 to 5" in line 3 to,
dor example, "1 to 10", you'll get 10 copies.

This is a simple Visual Basic programming loop that counts from one number
to another number and places the value of the count in the footer string.

Hope this helps, and that it encourages you to try some VBA of your own! Try
recording code as you do things, and going into the module to see how code
gets built up!

Regards

Pete





Sub MultiPrint()
Dim PrintCount As Integer
For PrintCount = 1 To 5
ActiveSheet.PageSetup.CenterFooter = "Page " & PrintCount
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Next
End Sub

"C&S" wrote:

How do you let the program know that you want to print multiple copies. It
is only printing one. I got it into the visual basic, but the print preview
only shows one copy. Thanks.



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
Print all charts in a workbook (multiple worksheets) aewsaws Charts and Charting in Excel 4 May 12th 23 03:45 AM
Entering Data in multiple cells on one sheet & having it auto upda haynblend Excel Worksheet Functions 2 March 27th 05 12:41 AM
Print multiple excel charts within one sheet to fit to a page lik. lal Excel Discussion (Misc queries) 1 February 18th 05 09:47 PM
set the print area print multiple tabs veng Excel Discussion (Misc queries) 5 February 12th 05 07:01 PM
linking multiple sheets to a summary sheet greg g Excel Discussion (Misc queries) 1 December 16th 04 07:43 AM


All times are GMT +1. The time now is 05:12 PM.

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

About Us

"It's about Microsoft Excel"