Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    Jan 2001
    Posts
    159
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Pausing in a Macro

    Excel 2000 - I have a macro that creates graphs. The final step of the macro I would like to print the graphs. But, I would like the option to select how many copies. I can't figure out how I would pause, like you can in Word. Any suggestions? Thanks!

  2. #2
    WS Lounge VIP rory's Avatar
    Join Date
    Dec 2000
    Location
    Burwash, East Sussex, United Kingdom
    Posts
    6,280
    Thanks
    3
    Thanked 191 Times in 177 Posts

    Re: Pausing in a Macro

    Hi Sherri,
    I would suggest either using .PrintPreview instead of .Print (so the user can make sure everything looks OK, then press Print where the option of number of copies will appear) or having an inputbox triggered, which will return the number of copies required:
    selectedsheets.printout Copies:=inputbox("How many copies?")
    though you'll need an error handler in case they press cancel.
    Hope that helps.
    Regards,
    Rory

    Microsoft MVP - Excel

  3. #3
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Dublin, Ireland, Republic of
    Posts
    2,697
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Pausing in a Macro

    You could use the following in your macro when you want it printed as it gives the opportunity (via a setup button) to select the number of copies and the actual printer you want to use. It also allows for general printer set-up, much as you would get if you select File Print.
    <pre> Sub PrintOut()
    Application.Dialogs(xlDialogPrinterSetup).Show
    End Sub</pre>


    Andrew C

Posting Permissions

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