LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
DRK DRK is offline
external usenet poster
 
Posts: 40
Default Building an array of worksheets for printing

I have one array that I use for printing a subset of worksheets in a
workbook. Baseline array is defined as:

Sheets(Array("Cover", "AboutThisIllustration", "PolicyValuesLedger", _
"PolicyValuesLedgerGuar", _
"PolicyValuesLedgerNonGuar")).Select

Depending on various Booleans I need to add other worksheets to the above.
Inclusion of these other worksheets is dependent on Booleans.

So if BoolBSIB is TRUE, then I need to add "PolicyValuesLedgerGuarGSIB", to
the above array BEFORE I get to the "PolicyValuesLedgerGuar", _

So it should read
Sheets(Array("Cover", "AboutThisIllustration", "PolicyValuesLedger", _
"PolicyValuesLedgerGuarGSIB", _
"PolicyValuesLedgerGuar", _
"PolicyValuesLedgerNonGuar")).Select


I'm stymied on how to build up this array inside of VBA. There are three
other worksheets that may or may not get printed. How can i do this inside of
VBA?

I'd hate to brute force it by building each potential variation but...I'd
prefer a more elegant solution.

--
DRK
 
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
Reference(s) to worksheets for building graphs PvZ Excel Worksheet Functions 4 June 1st 10 01:08 PM
printing an array of worksheets Marco de Witte Excel Discussion (Misc queries) 4 December 8th 04 03:21 PM
Building an Array Otto Moehrbach[_6_] Excel Programming 5 September 24th 04 01:30 PM
Building/Creating an Array Rich Cooper Excel Programming 8 May 26th 04 06:57 PM
Sheets(array) method for printing grouped worksheets Tom Ogilvy Excel Programming 0 July 17th 03 09:11 PM


All times are GMT +1. The time now is 07:46 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"