MrExcel Publishing
Your One Stop for Excel Tips & Solutions

Macro to print


Posted by Brad on January 21, 2002 1:41 PM

This is probably pretty obvious but I can't make a macro that brings up the print screen (ctr+p). Thanks for any help in advance.


Posted by Qroozn on January 21, 2002 1:44 PM

why doi you want it to bring up the printscreen?

is it to change the number of copies in the macro?

Posted by Brad on January 21, 2002 2:18 PM

It's for this system I am doing for A-Level ICT. I need a macro that will print off the worksheet the macro is placed on.

Posted by Qroozn on January 21, 2002 2:34 PM

this is the line of code. if you ever want to find cose like that then just record the macro witht he macro wizard. then look at the script that was recorded behind the macro.

ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True

this code will print out one copy of your selected worksheet.hope it helps you out!

Posted by Brad on January 21, 2002 2:44 PM

thanks. That is pretty much what I was looking for

Posted by Qroozn on January 21, 2002 2:46 PM

no problem.
all the best with the certification