#1   Report Post  
Mark
 
Posts: n/a
Default Print

I have a workbook with 3 sheets.
how can i add a command button to sheet one to print all
three sheets

thanks
  #2   Report Post  
OJ
 
Posts: n/a
Default

Hi,
1. Right click the toolbar area in Excel.
2. Select Forms Toolbar.
3. Select Command Button on the toolbar
4. Draw the button on the worksheet by holding down the left mouse
button and dragging.
5. Click Edit in the Dialogue Button
6. Enter the following code

Sub Button1_Click()
Dim intInc As Integer

With ThisWorkbook
For intInc = 1 To .Sheets.Count
.Sheets(intInc).PrintOut Copies:=1, Collate:=True
Next intInc
End With
End Sub



Hth,
Oli

  #3   Report Post  
 
Posts: n/a
Default

Thanks for this it worked a treat
-----Original Message-----
Hi,
1. Right click the toolbar area in Excel.
2. Select Forms Toolbar.
3. Select Command Button on the toolbar
4. Draw the button on the worksheet by holding down the

left mouse
button and dragging.
5. Click Edit in the Dialogue Button
6. Enter the following code

Sub Button1_Click()
Dim intInc As Integer

With ThisWorkbook
For intInc = 1 To .Sheets.Count
.Sheets(intInc).PrintOut Copies:=1, Collate:=True
Next intInc
End With
End Sub



Hth,
Oli

.

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
Dynamic Print Range Help waxwing Excel Worksheet Functions 2 February 21st 05 04:47 PM
set the print area print multiple tabs veng Excel Discussion (Misc queries) 5 February 12th 05 08:01 PM
Printing - Have to set print area 1 column further than necessary STUART BISSET Excel Discussion (Misc queries) 0 January 24th 05 08:59 PM
Microsoft Excel could not find anything to print cyndi Excel Discussion (Misc queries) 1 December 22nd 04 02:40 PM
Non-Breaking Space + Print Issue Barb Reinhardt Charts and Charting in Excel 3 December 9th 04 02:03 AM


All times are GMT +1. The time now is 04:08 PM.

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"