+ Reply to Thread
Results 1 to 5 of 5

Change #NA to 0

Hybrid View

grlnexdor Change #NA to 0 04-16-2014, 04:56 AM
Richard Buttrey Re: Change #NA to 0 04-16-2014, 05:09 AM
Kaper Re: Change #NA to 0 04-16-2014, 05:09 AM
Kaper Re: Change #NA to 0 04-16-2014, 05:11 AM
grlnexdor Re: Change #NA to 0 05-19-2014, 01:22 AM
  1. #1
    Registered User
    Join Date
    08-11-2010
    Location
    Singapore
    MS-Off Ver
    Excel 2003
    Posts
    28

    Change #NA to 0

    Hi All,

    I have a formula below:

    =VLOOKUP(D$2,CHOOSE(VLOOKUP($B3,$L$2:$M$8,2,0),TSBC2013!$C$5:$G$8,TSBC2013!$C$10:$G$12,TSBC2013!$C$14:$G$16,TSBC2013!$C$18:$G$20,TSBC2013!$C$22:$G$25,TSBC2013!$C$27:$G$28,TSBC2013!$C$30:$G$31),5,0)

    When there's no entry it is coming out as #NA. I am trying to update #NA entries to 0.

    I have tried =IFERROR and =IF(ISNA) but both coming out as "too many arguments error.

    I have tried applying VBA:

    "Cells.Replace "#N/A","",xlWhole" - but no change to my workbook when I apply.

    "Cells.SpecialCells(xlCellTypeFormulas,xlErrors).Clear" - the #NA value is cleared but I need it to be 0 not empty field.


    Can someone advise what am I doing wrong or is there any better solution than this?


    Thanks in advance!

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Change #NA to 0

    Hi,

    Are you able to share the workbook with us? Cut down and anonymised if necessary. We only need to see a representative sample.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,864

    Re: Change #NA to 0

    if you have excel 2003 as stated in profile - there was no IFERROR function so you should get NAME error
    try
    =IF(ISERROR(yourformula),0,yourformula)
    if 2007+
    =IFERROR(VLOOKUP(D$2,CHOOSE(VLOOKUP($B3,$L$2:$M$8,2,0),TSBC2013!$C$5:$G$8,TSBC2013!$C$10:$G$12,TSBC2013!$C$14:$G$16,TSBC2013!$C$18:$G$20,TSBC2013!$C$22:$G$25,TSBC2013!$C$27:$G$28,TSBC2013!$C$30:$G$31),5,0),0)
    shall work.
    Best Regards,

    Kaper

  4. #4
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,864

    Re: Change #NA to 0

    PS. for VBA - try:
    Cells.SpecialCells(xlCellTypeFormulas,xlErrors).value=0

  5. #5
    Registered User
    Join Date
    08-11-2010
    Location
    Singapore
    MS-Off Ver
    Excel 2003
    Posts
    28

    Re: Change #NA to 0

    I used this:

    =IFERROR(VLOOKUP(D$2,CHOOSE(VLOOKUP($B3,$L$2:$M$8,2,0),TSBC2013!$C$5:$G$8,TSBC2013!$C$10:$G$12,TSBC2013!$C$14:$G$16,TSBC2013!$C$18:$G$20,TSBC2013!$C$22:$G$25,TSBC2013!$C$27:$G$28,TSBC2013!$C$30:$G

    and it worked.

    Thanks!

+ 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. [SOLVED] Change all matching Value based on number change in Column Excel 2007
    By Excelnoub in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 02-20-2014, 11:40 AM
  2. Replies: 3
    Last Post: 06-20-2013, 11:10 AM
  3. Replies: 5
    Last Post: 02-01-2013, 12:58 PM
  4. Replies: 15
    Last Post: 04-17-2012, 08:19 AM
  5. auto change cell formula on condition of worksheet change in other cells
    By futurejock in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 06-01-2009, 12:11 AM

Tags for this Thread

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