+ Reply to Thread
Results 1 to 10 of 10

Change formula that removes blank cells to also exclude certain text from output list.

  1. #1
    Forum Contributor Big.Moe's Avatar
    Join Date
    03-15-2012
    Location
    Corea, Maine, USA
    MS-Off Ver
    Excel 2010
    Posts
    244

    Change formula that removes blank cells to also exclude certain text from output list.

    In the attached file (starting @ G470), I'm using the following formula to create a 'summation' of daily sales without all the blank cells:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Everything works great except for, due to print-out formatting, I had to insert the column headers at each print page break, and hence the header text gets picked-up by the formula and gets included in the list. Is there a way to append this formula to exclude these headers?
    Attached Images Attached Images
    Attached Files Attached Files

  2. #2
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    cant you use the page setup >> sheet tab >> check the "Rows to repeat at top:" section instead?
    Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
    Sam Capricci

  3. #3
    Forum Contributor Big.Moe's Avatar
    Join Date
    03-15-2012
    Location
    Corea, Maine, USA
    MS-Off Ver
    Excel 2010
    Posts
    244

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    Can't use that due to office print-out customization demands.

  4. #4
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    Give this a go

    =IFERROR(INDEX($G$40:$G$466,SMALL((IF(IFERROR(SIGN($G$40:$G$466),0),ROW($G$40:$G$466)-ROW($G$40)+1)),ROWS($G$470:$G470))),"")

    edit:-

    Just noticed that your original formula returned cells that contained 0, which this will not. Time to start again.

    second edit:-

    This one will find the 0 value non blank cells.

    =IFERROR(INDEX($G$40:$G$466,SMALL((IF(IFERROR((LEN($G$40:$G$466)+$G$40:$G$466)>0,0),ROW($G$40:$G$466)-ROW($G$40)+1)),ROWS($G$470:$G470))),"")

    I'll leave both formulas here so you can choose which will suit your need best.
    Last edited by jason.b75; 07-26-2018 at 03:11 PM.

  5. #5
    Forum Contributor Big.Moe's Avatar
    Join Date
    03-15-2012
    Location
    Corea, Maine, USA
    MS-Off Ver
    Excel 2010
    Posts
    244

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    jason.b75

    Let me play with that formula a bit, the zero thing may end up not being a factor.

  6. #6
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    Just edited my post again, first formula will not return 0 values, second one will. Both ignore blanks and text.

  7. #7
    Forum Contributor Big.Moe's Avatar
    Join Date
    03-15-2012
    Location
    Corea, Maine, USA
    MS-Off Ver
    Excel 2010
    Posts
    244

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    jason.b75

    So sorry, the zero thing IS indeed a factor in that sometimes items are comp'ed and hence have a zero price. Plus, I will be using the same formula in the other columns which will include negative numbers as well.

    Is there a way to incorporate ISNUMBER perhaps?

    edit:
    Playing with 2nd formula....
    Last edited by Big.Moe; 07-26-2018 at 03:22 PM.

  8. #8
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    Quote Originally Posted by Big.Moe View Post
    Is there a way to incorporate ISNUMBER perhaps?
    Sometimes it is so easy to overlook something because it is too obvious

    =IFERROR(INDEX($G$40:$G$466,SMALL((IF(ISNUMBER($G$40:$G$466),ROW($G$40:$G$466)-ROW($G$40)+1)),ROWS($G$470:$G470))),"")

  9. #9
    Forum Contributor Big.Moe's Avatar
    Join Date
    03-15-2012
    Location
    Corea, Maine, USA
    MS-Off Ver
    Excel 2010
    Posts
    244

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    jason.b75, you are a genius!

    Although I got your 2nd formula to work with the negative numbers by changing this portion LEN($G$40:$G$466)+$G$40:$G$466)>0 to this LEN($G$40:$G$466)+$G$40:$G$466)<>0, your third formula is perfection.

    Thanks so much for sticking with it & finding the ultimate solution! You sir are an Excel savior.

  10. #10
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: Change formula that removes blank cells to also exclude certain text from output list.

    You're welcome!

    Thanks for the feedback (and for suggesting the obvious thing that I had overlooked)

+ 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. Exclude blank cells from COUNTIFS formula
    By Leahsco in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 08-05-2014, 11:45 AM
  2. [SOLVED] Formula SUM - exclude cells with text / value problem
    By renix in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 02-04-2014, 09:48 AM
  3. Replies: 5
    Last Post: 05-09-2013, 01:16 AM
  4. Getting Rank formula to exclude zero and blank cells
    By Catherine01 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 04-11-2013, 06:10 AM
  5. Exclude blank/FALSE cells in in Excel array IF formula output
    By sushix in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 03-08-2013, 11:42 AM
  6. (SOLVED) Drop down list removes used cells
    By SubwAy in forum Excel General
    Replies: 5
    Last Post: 10-22-2011, 01:56 PM
  7. How to delete cells having formula with blank output?
    By Damongz in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-12-2011, 03:13 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