+ Reply to Thread
Results 1 to 8 of 8

Print-Macro help

  1. #1
    Registered User
    Join Date
    09-13-2013
    Location
    Philippines
    MS-Off Ver
    Excel 2013
    Posts
    17

    Print-Macro help

    Hi everyone. I have a template which is an excel file. It has 2 sheets in it, Sheet 1 and Sheet 2. I wish to make a Print button and place it in Sheet 1 then pressing it will print the 1st page of Sheet 2 only. Can you guys help me make a macro for it. thanks..

  2. #2
    Registered User
    Join Date
    09-12-2013
    Location
    Holland
    MS-Off Ver
    Excel 2013
    Posts
    13

    Re: Print-Macro help

    Place a commandbutton on Sheet 1 and put this code in the VBA Editor on Sheet1

    Please Login or Register  to view this content.
    Place the next code in Module1

    Please Login or Register  to view this content.



    Please Login or Register  to view this content.
    To find the right name of your printer, print a sheet while running the macrorecorder.

  3. #3
    Registered User
    Join Date
    09-13-2013
    Location
    Philippines
    MS-Off Ver
    Excel 2013
    Posts
    17

    Re: Print-Macro help

    geez..thanks a lot!

  4. #4
    Registered User
    Join Date
    09-13-2013
    Location
    Philippines
    MS-Off Ver
    Excel 2013
    Posts
    17

    Re: Print-Macro help

    Hi again Mr. h.veen!

    Sir, if it isn't much to ask, could you please attach an example .xls file with this code you've given because when i tried pasting the code, i only got error. I'm sorry but I really don't know much about macros.

  5. #5
    Registered User
    Join Date
    09-12-2013
    Location
    Holland
    MS-Off Ver
    Excel 2013
    Posts
    13

    Re: Print-Macro help

    Can you upload your file?

  6. #6
    Registered User
    Join Date
    09-12-2013
    Location
    Holland
    MS-Off Ver
    Excel 2013
    Posts
    13

    Re: Print-Macro help

    Try this file. It makes a print preview of sheet2
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    09-13-2013
    Location
    Philippines
    MS-Off Ver
    Excel 2013
    Posts
    17

    Re: Print-Macro help

    thanks again Mr. h.veen for your time. Please take a look at this file below. Also, i wish to rename the "CommandButton1" into "Print Form", is it possible to change that? (i forgot, the file is protected, it's password is jld)...
    Attached Files Attached Files
    Last edited by jamesdigol; 09-14-2013 at 10:00 PM.

  8. #8
    Registered User
    Join Date
    09-12-2013
    Location
    Holland
    MS-Off Ver
    Excel 2013
    Posts
    13

    Re: Print-Macro help

    Try this file.
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    09-13-2013
    Location
    Philippines
    MS-Off Ver
    Excel 2013
    Posts
    17

    Re: Print-Macro help

    wow great!...thanks a lot mr. hveen i hope this won't be the last. ur such a great help

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Print Macro errors on final print command. Run-time error '1004':
    By Steverizer in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-05-2013, 06:41 PM
  2. [SOLVED] Pivot Table macro to set print area and print details of drill down data
    By Steve Haskins in forum Excel General
    Replies: 2
    Last Post: 12-28-2005, 01:10 PM
  3. Replies: 1
    Last Post: 10-27-2005, 06:00 PM
  4. Create a print macro that would automatically select print area?
    By Ron de Bruin in forum Excel Formulas & Functions
    Replies: 21
    Last Post: 09-06-2005, 09:05 AM
  5. Create a print macro that would automatically select print area?
    By Ron de Bruin in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-06-2005, 04:05 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1