Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Old May 7th 09, 08:03 AM posted to microsoft.public.excel.misc
external usenet poster
 
First recorded activity by ExcelBanter: Jul 2006
Posts: 46
Default Check multiple cells for a match

I am trying to create a formula that checks multiple specific cells and then
returns a "YES" if it matches or a "NO" if it doesn't match any of the cells.

example

I have two worksheets - 1 and 2
I want to search these cells only on worksheet 1- cells B3, B24, B63, B78,
B89 (But none of the cells in between such as B4, B35, etc) for a match with
worksheet 2 cell A2.

Is this possible?

TIA.

Rusty

  #2   Report Post  
Old May 7th 09, 08:56 AM posted to microsoft.public.excel.misc
external usenet poster
 
First recorded activity by ExcelBanter: Jul 2006
Posts: 2,646
Default Check multiple cells for a match

=IF(OR(B3=Sheet2!A2,B24=Sheet2!A2,B63=Sheet2!A2,B7 8=Sheet2!A2,B89=Sheet2!A2),"Yes","No")
Regards,
Stefi

„Rusty” ezt *rta:

I am trying to create a formula that checks multiple specific cells and then
returns a "YES" if it matches or a "NO" if it doesn't match any of the cells.

example

I have two worksheets - 1 and 2
I want to search these cells only on worksheet 1- cells B3, B24, B63, B78,
B89 (But none of the cells in between such as B4, B35, etc) for a match with
worksheet 2 cell A2.

Is this possible?

TIA.

Rusty

  #3   Report Post  
Old May 7th 09, 01:34 PM posted to microsoft.public.excel.misc
external usenet poster
 
First recorded activity by ExcelBanter: Jul 2006
Posts: 10,124
Default Check multiple cells for a match

Or a macro approach. Modify to suit

Sub checkcertaincells()
For Each i In Range("c4,c6,c10")
If i = Range("f7") Then mycount = mycount + 1
Next i
If mycount 0 Then MsgBox "There are " & mycount & " matches"
End Sub


--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Rusty" wrote in message
...
I am trying to create a formula that checks multiple specific cells and
then
returns a "YES" if it matches or a "NO" if it doesn't match any of the
cells.

example

I have two worksheets - 1 and 2
I want to search these cells only on worksheet 1- cells B3, B24, B63, B78,
B89 (But none of the cells in between such as B4, B35, etc) for a match
with
worksheet 2 cell A2.

Is this possible?

TIA.

Rusty


  #4   Report Post  
Old May 8th 09, 02:40 AM posted to microsoft.public.excel.misc
external usenet poster
 
First recorded activity by ExcelBanter: Jul 2006
Posts: 46
Default Check multiple cells for a match

Thanks Stefi and Don. I'll go with Stefi's as it was the first one I tried
and it is working great.

Thankyou

"Stefi" wrote:

=IF(OR(B3=Sheet2!A2,B24=Sheet2!A2,B63=Sheet2!A2,B7 8=Sheet2!A2,B89=Sheet2!A2),"Yes","No")
Regards,
Stefi

„Rusty” ezt *rta:

I am trying to create a formula that checks multiple specific cells and then
returns a "YES" if it matches or a "NO" if it doesn't match any of the cells.

example

I have two worksheets - 1 and 2
I want to search these cells only on worksheet 1- cells B3, B24, B63, B78,
B89 (But none of the cells in between such as B4, B35, etc) for a match with
worksheet 2 cell A2.

Is this possible?

TIA.

Rusty

  #5   Report Post  
Old May 15th 09, 06:57 AM posted to microsoft.public.excel.misc
external usenet poster
 
First recorded activity by ExcelBanter: Jul 2006
Posts: 2,646
Default Check multiple cells for a match

You are welcome! Thanks for the feedback!
Stefi

„Rusty” ezt *rta:

Thanks Stefi and Don. I'll go with Stefi's as it was the first one I tried
and it is working great.

Thankyou

"Stefi" wrote:

=IF(OR(B3=Sheet2!A2,B24=Sheet2!A2,B63=Sheet2!A2,B7 8=Sheet2!A2,B89=Sheet2!A2),"Yes","No")
Regards,
Stefi

„Rusty” ezt *rta:

I am trying to create a formula that checks multiple specific cells and then
returns a "YES" if it matches or a "NO" if it doesn't match any of the cells.

example

I have two worksheets - 1 and 2
I want to search these cells only on worksheet 1- cells B3, B24, B63, B78,
B89 (But none of the cells in between such as B4, B35, etc) for a match with
worksheet 2 cell A2.

Is this possible?

TIA.

Rusty



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
Match multiple cells Gunti Excel Discussion (Misc queries) 6 November 12th 08 01:23 PM
link check boxes in multiple cells Taz22i Excel Discussion (Misc queries) 1 July 17th 08 04:24 PM
syntax for "IF" commend to check for multiple empty cells bf comma Chris Excel Worksheet Functions 4 September 3rd 07 12:02 PM
Check if 2 cells match on another sheet then lookup value sarahmarsden Excel Worksheet Functions 1 October 20th 06 12:19 PM
How to check multiple cells Sharon Mann Excel Worksheet Functions 3 January 22nd 06 02:35 PM


All times are GMT +1. The time now is 06:34 AM.

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

About Us

"It's about Microsoft Excel"

 

Copyright © 2017