Home |
Search |
Today's Posts |
#1
|
|||
|
|||
UserForm Print Extra Copies
Hi
On a user form I have a command button "Print1" which on clicking uses the following macro to print the sheet Sub Macro4() Sheets("Print1").Select ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True End Sub What would I need to add so that on clicking the command button it would ask how many copies required. Any help much appreciated Cheers Mully |
#2
|
|||
|
|||
Try this: Dim x As Integer x = InputBox("Number of copies?", "Print") If x 0 Then ActiveWindow.SelectedSheets.PrintOut Copies:=x, Collate:=True Else End If or you could use this: Application.Dialogs(xlDialogPrinterSetup).Show "mully" wrote: Hi On a user form I have a command button "Print1" which on clicking uses the following macro to print the sheet Sub Macro4() Sheets("Print1").Select ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True End Sub What would I need to add so that on clicking the command button it would ask how many copies required. Any help much appreciated Cheers Mully |
#3
|
|||
|
|||
Hi David
Thanks it worked perfectly 1st time of trying -- just one query is it possible within the dialog box to tell it which sheet to print in the workbook e.g. 10 copies of "Sheet 3" and then after finishing the print run open the dialog box again 5 copies "Sheet4" Once again thanks for all your help. Cheers Mully "David Hepner" wrote: Try this: Dim x As Integer x = InputBox("Number of copies?", "Print") If x 0 Then ActiveWindow.SelectedSheets.PrintOut Copies:=x, Collate:=True Else End If or you could use this: Application.Dialogs(xlDialogPrinterSetup).Show "mully" wrote: Hi On a user form I have a command button "Print1" which on clicking uses the following macro to print the sheet Sub Macro4() Sheets("Print1").Select ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True End Sub What would I need to add so that on clicking the command button it would ask how many copies required. Any help much appreciated Cheers Mully |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Print Copy limit | Excel Discussion (Misc queries) | |||
HOW DO I PRINT MULTIPLE COPIES IN EXCEL | Excel Discussion (Misc queries) | |||
print multiple copies of the same page with sequential numbers | Excel Discussion (Misc queries) | |||
Can one have an extra margin gutter, for binding a document print. | Excel Discussion (Misc queries) | |||
Printing - Have to set print area 1 column further than necessary | Excel Discussion (Misc queries) |