#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 41
Default IF Function

Im trying to get a value from 6 cells. Im entering the if function into B2.
cells C2, D2, E2, F2, G2 & H2 have either #N/A or the the answer Im looking
for but the answer is not always the same.

If C2 = #N/A then I want it to look in D2, if D2 = #N/A and so on until it
finds the cell that doesnt equal #N/A.

Please help, trying to work this out is doing my head in..........

Thanks,
Kirk
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default IF Function

Try this

=INDEX(C2:H2,MATCH(FALSE,ISNA(C2:H2),0))

'This is an array formula which must be entered with CTRL+Shift+Enter and NOT
'just enter. If you do it correctly then Excel will put curly brackets around
'the formula{}. You can't type these yourself. If you Edit the ranges
'then you must re-enter as An array

Mike

"Kirk" wrote:

Im trying to get a value from 6 cells. Im entering the if function into B2.
cells C2, D2, E2, F2, G2 & H2 have either #N/A or the the answer Im looking
for but the answer is not always the same.

If C2 = #N/A then I want it to look in D2, if D2 = #N/A and so on until it
finds the cell that doesnt equal #N/A.

Please help, trying to work this out is doing my head in..........

Thanks,
Kirk

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 41
Default IF Function

It works,

I never would have got that formular, I tried to enter it without the
shift+ctrl and it didnt work so I went back and read it.

Thanks for your help.
Kirk

"Mike H" wrote:

Try this

=INDEX(C2:H2,MATCH(FALSE,ISNA(C2:H2),0))

'This is an array formula which must be entered with CTRL+Shift+Enter and NOT
'just enter. If you do it correctly then Excel will put curly brackets around
'the formula{}. You can't type these yourself. If you Edit the ranges
'then you must re-enter as An array

Mike

"Kirk" wrote:

Im trying to get a value from 6 cells. Im entering the if function into B2.
cells C2, D2, E2, F2, G2 & H2 have either #N/A or the the answer Im looking
for but the answer is not always the same.

If C2 = #N/A then I want it to look in D2, if D2 = #N/A and so on until it
finds the cell that doesnt equal #N/A.

Please help, trying to work this out is doing my head in..........

Thanks,
Kirk

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,805
Default IF Function

Try this in B2
=INDIRECT("R2C"&LOOKUP(2,1/C2:H2,COLUMN(C:H)),FALSE)

"Kirk" wrote:

Im trying to get a value from 6 cells. Im entering the if function into B2.
cells C2, D2, E2, F2, G2 & H2 have either #N/A or the the answer Im looking
for but the answer is not always the same.

If C2 = #N/A then I want it to look in D2, if D2 = #N/A and so on until it
finds the cell that doesnt equal #N/A.

Please help, trying to work this out is doing my head in..........

Thanks,
Kirk

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
copy of excel file not showing formulal/function in the function b oaallam Excel Discussion (Misc queries) 4 September 6th 07 01:20 PM
LINKEDRANGE function - a complement to the PULL function (for getting values from a closed workbook) [email protected] Excel Worksheet Functions 0 September 5th 06 03:44 PM
Offset function with nested match function not finding host ss. MKunert Excel Worksheet Functions 1 March 21st 06 10:46 PM
Emulate Index/Match combo function w/ VBA custom function Spencer Hutton Excel Worksheet Functions 2 May 2nd 05 05:26 PM
Nested IF Function, Date Comparing, and NetworkDays Function carl Excel Worksheet Functions 2 December 29th 04 09:57 PM


All times are GMT +1. The time now is 07:14 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"