Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Using a macro to select a print range

What I have is a count function that counts the range A42:A100 in cell Z3 on
a sheet called "Start". What I am trying to do is based on that count
function to select a range that I have defined (tag1,tag2,....tag8) on a a
sheet calld "Lables" and print it based on the results of the count function
in cell Z3. I am hoping to be able to do this in a macro.
Any help will be very appreciated

Thank You

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200605/1
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Using a macro to select a print range

With worksheets("Start")
set rng = .Range("Z3")
End with
i = rng.value
with worksheets(Lables")
set rng1 = .Range("tag" & i)
.PageSetup.PrintArea = "Lables!" & rng1.Address(1,1)
.Printout
End with

--
Regards,
Tom Ogilvy



"mrc1986 via OfficeKB.com" wrote:

What I have is a count function that counts the range A42:A100 in cell Z3 on
a sheet called "Start". What I am trying to do is based on that count
function to select a range that I have defined (tag1,tag2,....tag8) on a a
sheet calld "Lables" and print it based on the results of the count function
in cell Z3. I am hoping to be able to do this in a macro.
Any help will be very appreciated

Thank You

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200605/1

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Using a macro to select a print range

This is exaclatally what I am trying to do. There is only one little problem
it always prints out on two pages nomatter which range it is printing. For
the most part it should only need one page.

Thank You,
Mark

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200605/1
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Using a macro to select a print range

I found my peoblem ids had some odd formatting in that worksheet. I put all
the info in a different worksheet and it works perfectly.


THAK YOU!!!!

mrc1986 wrote:
This is exaclatally what I am trying to do. There is only one little problem
it always prints out on two pages nomatter which range it is printing. For
the most part it should only need one page.

Thank You,
Mark


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200605/1
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
Macro to select and print sheets JoeP Excel Discussion (Misc queries) 3 April 19th 07 06:44 PM
Select Worksheet to print Macro Angel_24477616 Excel Worksheet Functions 0 March 19th 07 12:56 PM
Create a print macro that would automatically select print area? wastedwings Excel Worksheet Functions 7 August 22nd 05 10:36 PM
How do I select a range to print if I have different numbers of ro Charles Bennington Excel Programming 2 March 29th 05 08:35 AM
My First User Form - How to Select Range(s) and Print Bruce Roberson[_2_] Excel Programming 3 July 25th 03 03:09 AM


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