+ Reply to Thread
Results 1 to 9 of 9

Dynamic Print Area that ignores blank cells containing formulas

  1. #1
    Registered User
    Join Date
    11-26-2013
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    9

    Dynamic Print Area that ignores blank cells containing formulas

    I have a spreadsheet report that contains info from cells A-P (some cells are merged).
    The report links to another spreadsheet in the workbook and enters the values in cells A8-A2020. Most of the time not all values are filled in, but sometimes they may be so I need to keep the formulas in place. Right now, if the linked cell has no value, the formula returns a blank (used the formula =IF('Raw Data'!A8="","",'Raw Data'!A8). This works except when I try to print, it also prints the blanks so with 1 sheet of actual filled data, it is printing 42 sheets (41 blank sheets). How can I set the range, or use a macro that will ignore the ending blank cells?
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,943

    Re: Dynamic Print Area that ignores blank cells containing formulas

    You can just filter to not show the null values using text filters on column A - then only the "filled" range of the print area will actually print.
    Bernie Deitrick
    Excel MVP 2000-2010

  3. #3
    Registered User
    Join Date
    11-26-2013
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    9

    Re: Dynamic Print Area that ignores blank cells containing formulas

    I tried that but it wouldn't work because the beginning of my data isn't at the top of the spreadsheet. I have other values at the top, similar to a form, where the user fills in particluar infomation about the data. Some of these cells are also merged. Please see my example attachment.

  4. #4
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,943

    Re: Dynamic Print Area that ignores blank cells containing formulas

    Example (2).xlsm

    Just filter on the part of your sheet that has the table with the formula....as shown in the attached.

  5. #5
    Registered User
    Join Date
    11-26-2013
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    9

    Re: Dynamic Print Area that ignores blank cells containing formulas

    That worked like a charm. Since others will be using this and might not know exactly what to filter, I recorded a macro button they will press to "refresh" the data so it realign the print area with the updated values. Thank you!!

  6. #6
    Registered User
    Join Date
    07-03-2017
    Location
    ice.goblin
    MS-Off Ver
    2013
    Posts
    2

    Re: Dynamic Print Area that ignores blank cells containing formulas

    I have a similar issue.
    Maybe I'm doing something wrong but here's what I'm trying to achieve. I have a table where each row represents an order number and each column represents a commodity. Each line being printed onto a separate paycheck. Obviously no clients have one of each commodity, they all usually just pick one or two. So I'd like it to skip blank cells when printing. Am I getting previous advice wrong or do I need a different approach?

    That's quite an old thread so I'll add that i'm using Office 2013.
    Last edited by ice.goblin; 07-03-2017 at 11:45 AM.

  7. #7
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,943

    Re: Dynamic Print Area that ignores blank cells containing formulas

    You need a different approach, since Excel cannot filter across rows to hide blanks. You could use formulas to extract non-blanks cells, or a macro to hide the columns with blanks values. It all depends on what exactly your work method is.

  8. #8
    Registered User
    Join Date
    07-03-2017
    Location
    ice.goblin
    MS-Off Ver
    2013
    Posts
    2

    Re: Dynamic Print Area that ignores blank cells containing formulas

    Wait, you are saying it cannot process rows in such a way, but what If i swap the axis and place it vertically? Will it work that way?
    And in any case, can you suggest a direct solution? I'm not really good with Excel but my cash desk software uses it.

  9. #9
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,943

    Re: Dynamic Print Area that ignores blank cells containing formulas

    If you copy your range and paste special / transpose, then you can use autofilters to hide blanks values in the column, but only on a column by column basis. Otherwise, if you post a small sample of what you have, and what you want, then someone can propose a formula or macro solution. But post it as a new question - I'm probably the only person looking at this thread becasue I had subscribed to it - if I had not, I never would have seen your post.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Dynamic named range that ignores formulas that return blank
    By Nils88 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-27-2013, 05:02 AM
  2. Dynamic Print Range not including blank rows with formulas
    By amartin575 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-12-2013, 11:49 AM
  3. Replies: 2
    Last Post: 01-04-2013, 04:22 PM
  4. Replies: 2
    Last Post: 07-11-2012, 08:58 AM
  5. Dynamic Range that ignores formulas that return Blank
    By oo0tommyk0oo in forum Excel General
    Replies: 10
    Last Post: 03-16-2011, 01:06 PM

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