Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 46
Default Print Entire Workbook

Hello,
I've complete a somewhat complex Macro that tests out fine. I'm getting
stuck on something that should be simple, but it's a big problem for me.
I'd like to automate the printout of an entire workbook. I'm creating a PDF
file, and Adobe uses Print to create their file.
It's important that all the pages in my workbook be numbered sequentially.
For example, if Worksheet 1 fit on 3 pages, then Worksheet 2 would start with
a page number of 4.
Can't I feed PrintOut the "Print What" section with "Entire Workbook"
somehow?
I've seen other programs loop through worksheets within a workbook, but the
page numbering would reset to 1 with each page. Isn't the "Entire Workbook"
option available to VBA?
Thanks for all your help.
--
Programmer on Budget
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,510
Default Print Entire Workbook


--
Regards,

OssieMac


"Budget Programmer" wrote:

Hello,
I've complete a somewhat complex Macro that tests out fine. I'm getting
stuck on something that should be simple, but it's a big problem for me.
I'd like to automate the printout of an entire workbook. I'm creating a PDF
file, and Adobe uses Print to create their file.
It's important that all the pages in my workbook be numbered sequentially.
For example, if Worksheet 1 fit on 3 pages, then Worksheet 2 would start with
a page number of 4.
Can't I feed PrintOut the "Print What" section with "Entire Workbook"
somehow?
I've seen other programs loop through worksheets within a workbook, but the
page numbering would reset to 1 with each page. Isn't the "Entire Workbook"
option available to VBA?
Thanks for all your help.
--
Programmer on Budget

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,510
Default Print Entire Workbook

Hi,

I have not tried to create PDF files other than in Excel 2007 which supports
it with a download from Microsoft. Therefore not sure if my answer will help.

Do you mean that you use print to create a pdf and you have to select pdf as
the printer to create the pdf file? If so, if you select File- print do you
not get the usual dialog box where you select the printer and at the bottom
left there is a section to Print what with the options: Selection, Active
sheet(s) and Entire workbook? This method usually numbers all the sheets
sequentially for the entire workbook.

Your quote "Isn't the "Entire Workbook" option available to VBA?

Usual code for this is:
ActiveWorkbook.Printout Copies:=1, Collate:=True


--
Regards,

OssieMac


"Budget Programmer" wrote:

Hello,
I've complete a somewhat complex Macro that tests out fine. I'm getting
stuck on something that should be simple, but it's a big problem for me.
I'd like to automate the printout of an entire workbook. I'm creating a PDF
file, and Adobe uses Print to create their file.
It's important that all the pages in my workbook be numbered sequentially.
For example, if Worksheet 1 fit on 3 pages, then Worksheet 2 would start with
a page number of 4.
Can't I feed PrintOut the "Print What" section with "Entire Workbook"
somehow?
I've seen other programs loop through worksheets within a workbook, but the
page numbering would reset to 1 with each page. Isn't the "Entire Workbook"
option available to VBA?
Thanks for all your help.
--
Programmer on Budget

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default Print Entire Workbook

Using the ActiveWorkbook.PrintOut would pring all of the pages in the
workbook for each worksheet, but it would not accomodate the page numbering
that you want. You would have to create a special file in another
application to get the page numbering.

"Budget Programmer" wrote:

Hello,
I've complete a somewhat complex Macro that tests out fine. I'm getting
stuck on something that should be simple, but it's a big problem for me.
I'd like to automate the printout of an entire workbook. I'm creating a PDF
file, and Adobe uses Print to create their file.
It's important that all the pages in my workbook be numbered sequentially.
For example, if Worksheet 1 fit on 3 pages, then Worksheet 2 would start with
a page number of 4.
Can't I feed PrintOut the "Print What" section with "Entire Workbook"
somehow?
I've seen other programs loop through worksheets within a workbook, but the
page numbering would reset to 1 with each page. Isn't the "Entire Workbook"
option available to VBA?
Thanks for all your help.
--
Programmer on Budget

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,346
Default Print Entire Workbook

Hi,

If you are talking about doing this in Excel 2007 - meaning printing it in
Excel not as a pdf, then you can do it

1. Select all the sheets in the workbook and add page number to the custom
footer or however, you want to do that.
2. Then with all the sheets selected issue the print command, the page
numbering will work between sheets.

--
If this helps, please click the Yes button

Cheers,
Shane Devenshire


"Budget Programmer" wrote:

Hello,
I've complete a somewhat complex Macro that tests out fine. I'm getting
stuck on something that should be simple, but it's a big problem for me.
I'd like to automate the printout of an entire workbook. I'm creating a PDF
file, and Adobe uses Print to create their file.
It's important that all the pages in my workbook be numbered sequentially.
For example, if Worksheet 1 fit on 3 pages, then Worksheet 2 would start with
a page number of 4.
Can't I feed PrintOut the "Print What" section with "Entire Workbook"
somehow?
I've seen other programs loop through worksheets within a workbook, but the
page numbering would reset to 1 with each page. Isn't the "Entire Workbook"
option available to VBA?
Thanks for all your help.
--
Programmer on Budget



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,510
Default Print Entire Workbook

Hi JLGWhiz,

Your quote "but it would not accomodate the page numbering that you want."

Under testing in both xl2002 and xl2007, ActiveWorkbook.PrintOut Copies:=1,
Collate:= True sequentially numbers the pages for the entire workbook.
Shane's suggestion also works in both xl2002 and xl2007. As an added extra,
the page setup can be different for each worksheet but how much different I
am not sure but they can certainly have different headers and the page
numbering is still sequential for the entire workbook and Page X of Y pages
also works.

As per my previous post, selecting file-print and then setting Entire
workbook also works in xl2002 and with xl2007 Microsoft button - Print -
Print Select printer ....etc then as for xl2002.
--
Regards,

OssieMac


"JLGWhiz" wrote:

Using the ActiveWorkbook.PrintOut would pring all of the pages in the
workbook for each worksheet, but it would not accomodate the page numbering
that you want. You would have to create a special file in another
application to get the page numbering.

"Budget Programmer" wrote:

Hello,
I've complete a somewhat complex Macro that tests out fine. I'm getting
stuck on something that should be simple, but it's a big problem for me.
I'd like to automate the printout of an entire workbook. I'm creating a PDF
file, and Adobe uses Print to create their file.
It's important that all the pages in my workbook be numbered sequentially.
For example, if Worksheet 1 fit on 3 pages, then Worksheet 2 would start with
a page number of 4.
Can't I feed PrintOut the "Print What" section with "Entire Workbook"
somehow?
I've seen other programs loop through worksheets within a workbook, but the
page numbering would reset to 1 with each page. Isn't the "Entire Workbook"
option available to VBA?
Thanks for all your help.
--
Programmer on Budget

  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 46
Default Print Entire Workbook

Hello Everyone,
The "ActiveWorkbook.PrintOut Copies:=1, Collate:= True" worked fine. I was
just looking for the "Entire Workbook" parameter of the PrintOut method and
didn't find it. I guess the parameter of "Entire Workbook" is implied in the
"ActiveWorkBOOK.Printout" method.
As far as Adobe Writer goes, it really doesn't matter. Adobe Writer just
configures a printer, and then captures the data that typically goes to a
printer and converts the data to a PDF file. As far as the Office
applications are concerned, it's just another pinter. I tested this with my
HP Officejet and got exactly the same results.
Thanks again Everyone for all your help.

--
Programmer on Budget


"Shane Devenshire" wrote:

Hi,

If you are talking about doing this in Excel 2007 - meaning printing it in
Excel not as a pdf, then you can do it

1. Select all the sheets in the workbook and add page number to the custom
footer or however, you want to do that.
2. Then with all the sheets selected issue the print command, the page
numbering will work between sheets.

--
If this helps, please click the Yes button

Cheers,
Shane Devenshire


"Budget Programmer" wrote:

Hello,
I've complete a somewhat complex Macro that tests out fine. I'm getting
stuck on something that should be simple, but it's a big problem for me.
I'd like to automate the printout of an entire workbook. I'm creating a PDF
file, and Adobe uses Print to create their file.
It's important that all the pages in my workbook be numbered sequentially.
For example, if Worksheet 1 fit on 3 pages, then Worksheet 2 would start with
a page number of 4.
Can't I feed PrintOut the "Print What" section with "Entire Workbook"
somehow?
I've seen other programs loop through worksheets within a workbook, but the
page numbering would reset to 1 with each page. Isn't the "Entire Workbook"
option available to VBA?
Thanks for all your help.
--
Programmer on Budget

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
Print Entire Workbook Rob Hudson[_2_] Excel Discussion (Misc queries) 3 July 10th 07 02:52 PM
set default to print out the entire workbook MSG Setting up and Configuration of Excel 0 August 7th 06 10:56 PM
Print Entire Workbook pr. default NFIT Setting up and Configuration of Excel 0 May 22nd 06 08:46 AM
Set 'Print Entire Workbook' as default? Mike Excel Discussion (Misc queries) 0 April 5th 06 09:23 PM
Macro to open print window and set to print entire workbook retseort Excel Discussion (Misc queries) 1 October 27th 05 11:00 PM


All times are GMT +1. The time now is 09:49 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"