Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Need formula to create a value in a single cell by searching a range

I am attempting to create a value(an error message actually) in a single cell
by "searching" for a given value anywhere in a column or range of cells. The
searched for value in the column is in response(via a formula) to certain
criteria from other values in other cells within same row(using IF, OR, AND
commands).
Does anyone have a fomula that would help me?

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,934
Default Need formula to create a value in a single cell by searching a range

You can use this formula as a guide...

=IF(COUNTIF(E4:H20,D1),"Value found in range!","Value not found!")

Change the range to suit, D1 is assumed to contain the value you are
searching for, or you can hard-code the value (example value 123) in like
this instead...

=IF(COUNTIF(E4:H20,123),"Value found in range!","Value not found!")

--
Rick (MVP - Excel)


"Stunzer" <u53932@uwe wrote in message news:9a7196c227c8a@uwe...
I am attempting to create a value(an error message actually) in a single
cell
by "searching" for a given value anywhere in a column or range of cells.
The
searched for value in the column is in response(via a formula) to certain
criteria from other values in other cells within same row(using IF, OR,
AND
commands).
Does anyone have a fomula that would help me?


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Need formula to create a value in a single cell by searching a range

Rick,

Awesome, worked well & is exactly what I needed...thanks for the quick
response also...

Stu

Rick Rothstein wrote:
You can use this formula as a guide...

=IF(COUNTIF(E4:H20,D1),"Value found in range!","Value not found!")

Change the range to suit, D1 is assumed to contain the value you are
searching for, or you can hard-code the value (example value 123) in like
this instead...

=IF(COUNTIF(E4:H20,123),"Value found in range!","Value not found!")

I am attempting to create a value(an error message actually) in a single
cell

[quoted text clipped - 5 lines]
commands).
Does anyone have a fomula that would help me?


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
Searching for values in a given range and then prepending a formula Ben Burns Excel Programming 2 June 18th 07 01:55 PM
Create Macro to copy a formula to range of cell summer Excel Programming 2 June 15th 07 04:52 AM
create formula to compare cell 1 with a range of cell KKXC Excel Programming 2 January 7th 06 06:37 AM
Can I create an IF formula for single cell w/ dif. text in Excel? bennymichael Excel Discussion (Misc queries) 1 July 21st 05 08:59 PM
Range.Find returns cell outside of range when range set to single cell Frank Jones Excel Programming 12 June 10th 04 04:22 AM


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

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

About Us

"It's about Microsoft Excel"