Solved

Excel VBA Button

Posted on 2011-09-20
4
168 Views
Last Modified: 2012-08-13
I would like some VBA which I can use in an Excel button which will allow me to bring up the print window for a defined tab winthin the workbook.

Thank you
0
Comment
Question by:jtr209
  • 3
4 Comments
 
LVL 12

Expert Comment

by:kgerb
ID: 36569696
Hello,
Will this work?

Kyle
Application.Dialogs(xlDialogPrint).Show

Open in new window

0
 
LVL 12

Accepted Solution

by:
kgerb earned 500 total points
ID: 36569731
If you would like to activate a specific sheet before showing the print dialogue then this will work.
Sub PrintSheet()
Sheets("Sheet2").Activate
Application.Dialogs(xlDialogPrint).Show
End Sub

Open in new window

0
 

Author Comment

by:jtr209
ID: 36569759
Thank You, that worked great!
0
 
LVL 12

Expert Comment

by:kgerb
ID: 36569774
You're welcome.  Thanks for the grade!

Kyle
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
using vb script 5 47
any combination of this numbers 9 28
Tricky shapes formula part 2 4 18
Checking references in VBA 3 21
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
Do you use a spreadsheet like Microsoft's Excel?  Have you ever wanted to link out to a non excel file on your computer or network drive?  This is the way I found to do it!
This Micro Tutorial demonstrate the bugs in Microsoft Excel for Mac with Pivot Charts.
This Micro Tutorial will demonstrate how to create pivot charts out of a data set. I also added a drop-down menu which allows to choose from different categories in the data set and the chart will automatically update.

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question