How can I turn #N/A N/A into "0"?

TwoAce

Board Regular
Joined
Feb 20, 2008
Messages
152
Office Version
  1. 365
Platform
  1. Windows
Dear all,

The following function is returning #N/A N/A: =BDP($D22,$BD$19)
This is because the feature (marketable securities=$BD$19) is not available for this security ($D22).
I would like this formula to be changed so it will return "0" (zero).
ISNA will get rid of a single #N/A for me, but I can't get it to do this for #N/A N/A.
I hope someone has a solution.

Thanks in advance! :)

TwoAce
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK
=IF(ISERROR(BDP($D22,$BD$19)),0,BDP($D22,$BD$19))

This is not working, it's still returning #N/A N/A unfortunately.
 
Upvote 0
I think we're going to need to see the code for the BDP function...

It's possible it's not actually an NA Error, maybe the resulting value from the BDP formula is actually #N/A N/A
 
Upvote 0
That could actually be the case, although I'm not quite sure. It's a code for Bloomberg, which can be used when the Bloomberg addin is installed.
I could find another way around it maybe, by adding an extra column that says if the cell in the previous column >0 then, take this value, if not, 0.
I have to recalculate from this value, and use the recalculated value again... but I think it might work like I described above. It just gets ugly with these extra columns (I need to apply it to other cells as well).

Thanks for the help, I'll see if it works the way I suggested. If anyone has other ideas, I'd like to hear it as well.
 
Upvote 0
Dear all,

The following function is returning #N/A N/A: =BDP($D22,$BD$19)
This is because the feature (marketable securities=$BD$19) is not available for this security ($D22).
I would like this formula to be changed so it will return "0" (zero).
ISNA will get rid of a single #N/A for me, but I can't get it to do this for #N/A N/A.
I hope someone has a solution.

Thanks in advance! :)

TwoAce

If BDP is supposed to return a number...

=LOOKUP(9.99999999999999E+307,CHOOSE({1,2},0,BDP($D22,$BD$19)))
 
Upvote 0
Aladin, as many times before you come up with the perfect solution. I could not have thought of it myself. Thanks a lot, you've made my day! :)

I've tried Jonmo1's solution as well, and it also works! I'll see which one I choose :-)
 
Last edited:
Upvote 0
Your topic reminded me of a funny thing that happened at work.

We run an answering service where we fill out a form and send a message.
Our agent asked the caller a series of questions - all of which were not applicable. The agent put NA in all the fields.

Pager owner rang and asked why we sent him a message that said " na na na na naaa!"

rofl - sorry to hijack your thread
 
Upvote 0

Forum statistics

Threads
1,224,091
Messages
6,176,298
Members
452,720
Latest member
Quazlat

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top