+ Reply to Thread
Results 1 to 4 of 4

Using a macro to select a print range

  1. #1
    mrc1986 via OfficeKB.com
    Guest

    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. #2
    Tom Ogilvy
    Guest

    RE: 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. #3
    mrc1986 via OfficeKB.com
    Guest

    RE: 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. #4
    mrc1986 via OfficeKB.com
    Guest

    RE: 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 to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1