+ Reply to Thread
Results 1 to 6 of 6

my formula produces an error instead of staying blank

Hybrid View

  1. #1
    Registered User
    Join Date
    06-03-2016
    Location
    England
    MS-Off Ver
    2013
    Posts
    35

    my formula produces an error instead of staying blank

    Hi all

    this is my formula

    =IF(G2=1,A2,AGGREGATE(15,6,A$2:A$31/((B$2:B$31=B2)*(D$2:D$31=D2)*(E$2:E$31=E2)),1))

    however, i have just realised that if the cells in the same row are blank it produces Jan-00 is there a way of changing it to stay blank?

    Many thanks

    Ashley

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,971

    Re: my formula produces an error instead of staying blank

    Do you mean that you want something adding to deal with G2 being blank? If so, try this:

    =IF(G2="","",IF(G2=1,A2,AGGREGATE(15,6,A$2:A$31/((B$2:B$31=B2)*(D$2:D$31=D2)*(E$2:E$31=E2)),1)))
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  3. #3
    Registered User
    Join Date
    06-03-2016
    Location
    England
    MS-Off Ver
    2013
    Posts
    35

    Re: my formula produces an error instead of staying blank

    brilliant! i was trying to make it happen after the initial IF. thanks Ali! works a treat!

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,971

    Re: my formula produces an error instead of staying blank

    No problem!

  5. #5
    Registered User
    Join Date
    06-03-2016
    Location
    England
    MS-Off Ver
    2013
    Posts
    35

    Re: my formula produces an error instead of staying blank

    Hey Ali, any chance you can explain why i would get #VALUE error with this one, when M3 is blank? - there is a formula in M3

    =IF(M3=" "," ",EDATE(M3,6))

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,971

    Re: my formula produces an error instead of staying blank

    Try this and tell me if it works:

    =IF(M3="","",EDATE(M3,6))

    No space between the speech marks.

+ 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. Errorhandler produces 1004 error
    By nickmax1 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-29-2015, 04:04 AM
  2. [SOLVED] Counting distinct values with blank cells produces #DIV/0!
    By antexity in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-14-2015, 09:00 AM
  3. Consolidate mulitple sheets produces error
    By gr8rck in forum Excel General
    Replies: 1
    Last Post: 02-14-2015, 04:17 AM
  4. Vlookup does not work, produces #N/A error, please help!!!
    By HC1994 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 02-04-2014, 04:45 PM
  5. [SOLVED] why this array produces an error?
    By BNCOXUK in forum Excel General
    Replies: 4
    Last Post: 12-03-2012, 11:54 AM
  6. Formula produces Error
    By treeleaf20 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-10-2009, 05:34 PM
  7. [SOLVED] Input box cancel produces error
    By pkeegs in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-12-2006, 01:10 AM

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