Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
dan dan is offline
external usenet poster
 
Posts: 866
Default GROUP PRINTING

I have four groups with three teams with different amount of people on the
teams my current code using team 1 as an example is:

Sheets(Array("T1-02", "T1-03", "T1-04", "T1-05", "T1-06", "T1-07",
"T1-08")).Select
Sheets("T1-02").Activate
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets("Team 1").Select

problem is those who have less get the form with no data. My question is can
I get a message box to enter the number of people on the team and print that?
and how 3 ppl = T1-01 to T1-03, 8 ppl is as you see above. Much thanks
appreciated
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default GROUP PRINTING

Dim varr as variant, varr1() as String
Dim res as Long
varr = Array("T1-02", "T1-03", "T1-04", "T1-05", _
"T1-06", "T1-07", "T1-08")
res = InputBox("how many people on the team?")
Redim varr1(0 to res - 1)
for i = 0 to res - 1
varr1(i) = varr(i)
Next
Sheets(varr1).Select
Sheets("T1-02").Activate
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets("Team 1").Select

--
Regards,
Tom Ogilvy

"Dan" wrote in message
...
I have four groups with three teams with different amount of people on the
teams my current code using team 1 as an example is:

Sheets(Array("T1-02", "T1-03", "T1-04", "T1-05", "T1-06", "T1-07",
"T1-08")).Select
Sheets("T1-02").Activate
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets("Team 1").Select

problem is those who have less get the form with no data. My question is

can
I get a message box to enter the number of people on the team and print

that?
and how 3 ppl = T1-01 to T1-03, 8 ppl is as you see above. Much thanks
appreciated



  #3   Report Post  
Posted to microsoft.public.excel.programming
Ben Ben is offline
external usenet poster
 
Posts: 509
Default GROUP PRINTING

have an input box to enter the upper and lower range of sheets to print, and
use a vstring variable to select the sheets

sheets(array("T1-"+t1,"T1-"+t2")) until you have your selected teams

"Dan" wrote:

I have four groups with three teams with different amount of people on the
teams my current code using team 1 as an example is:

Sheets(Array("T1-02", "T1-03", "T1-04", "T1-05", "T1-06", "T1-07",
"T1-08")).Select
Sheets("T1-02").Activate
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets("Team 1").Select

problem is those who have less get the form with no data. My question is can
I get a message box to enter the number of people on the team and print that?
and how 3 ppl = T1-01 to T1-03, 8 ppl is as you see above. Much thanks
appreciated

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
Printing a group of worksheets Pat Adams Excel Discussion (Misc queries) 1 July 1st 08 05:00 PM
Printing a group that is not grouped jerminski73 Excel Discussion (Misc queries) 2 May 22nd 07 07:38 PM
Printing spreadsheets with values entered (group) jerminski73 Excel Discussion (Misc queries) 0 April 26th 07 07:40 PM
printing group of charts tony Charts and Charting in Excel 1 September 4th 06 11:27 PM
(new to the group) importing data into excel and printing george Excel Programming 1 October 2nd 04 11:11 AM


All times are GMT +1. The time now is 07:55 PM.

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"