+ Reply to Thread
Results 1 to 6 of 6

#DIV/0! error - need help correcting against particular formula

  1. #1
    Registered User
    Join Date
    12-30-2011
    Location
    UK
    MS-Off Ver
    Excel 2013
    Posts
    49

    #DIV/0! error - need help correcting against particular formula

    Hello again,

    I have the DIV error. And I have the below formula. What do I need to add to return "0" instead of #DIV/0! please

    =IF(ISERROR(VLOOKUP(A3,CtyHrs,3,FALSE)),0,VLOOKUP(A3,CtyHrs,3,FALSE))/K2

    Cell K2 is hours and some of these cells contain "0" where i get the error.

    Thanks for your patience

  2. #2
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,527

    Re: #DIV/0! error - need help correcting against particular formula

    Hi Nubian,

    You need to incorporate the divsion into the ISERROR section of the formula, i.e.:

    =IF(ISERROR(VLOOKUP(A3,CtyHrs,3,FALSE)/K2),0,VLOOKUP(A3,CtyHrs,3,FALSE)/K2)

    HTH

    Robert
    ____________________________________________
    Please ensure you mark your thread as Solved once it is. Click here to see how
    If this post helps, please don't forget to say thanks by clicking the star icon in the bottom left-hand corner of my post

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: #DIV/0! error - need help correcting against particular formula

    Or =IF(N(K2), VLOOKUP(A3, CtyHrs, 3, FALSE)/K2, 0)
    Last edited by shg; 04-18-2012 at 08:07 PM.
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Registered User
    Join Date
    12-30-2011
    Location
    UK
    MS-Off Ver
    Excel 2013
    Posts
    49

    Re: #DIV/0! error - need help correcting against particular formula

    Many thanks Robert, this solved it

  5. #5
    Registered User
    Join Date
    12-30-2011
    Location
    UK
    MS-Off Ver
    Excel 2013
    Posts
    49

    Re: #DIV/0! error - need help correcting against particular formula

    and thank you shg

  6. #6
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,527

    Re: #DIV/0! error - need help correcting against particular formula

    Nubian,

    Thanks for letting us know.

    Please mark the thread as solved when you get a chance.

    shg,

    We must be on the same wave length or something!!

    Regards,

    Robert

+ 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