Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default Use cell content (example: ="a") in formula.

Hello all,

How can I use the content of a cell as rule in a formula?

Exammple:

A2 has a
A3 has b
a4 has c
etc, etc.

Content of B1 is (as text): ="a"

I want to have a formula in b2 where the content of B2 is used to compare if A2 is ="a" (the content of B2)
So something like:
=IF(A2 & B1 & ;1;2)

it will have the same effect as =IF(A2="a";1;2) where the comparision with "a" is hardcoded.


Thanks in advance for any hint or help!

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 538
Default Use cell content (example: ="a") in formula.

R0nald wrote:

How can I use the content of a cell as rule in a formula?

Exammple:

A2 has a
A3 has b
a4 has c
etc, etc.

Content of B1 is (as text): ="a"

I want to have a formula in b2 where the content of B2 is used to compare
if A2 is ="a" (the content of B2)
So something like:
=IF(A2 & B1 & ;1;2)

it will have the same effect as =IF(A2="a";1;2) where the comparision with
"a" is hardcoded.


So, something like this?

=IF(A2=B2,1,2)

--
Sometimes you wake up.
Sometimes the fall kills you.
And sometimes, when you fall, you fly.
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
Can a formula be "built" referencing text content from another cel Pradhan Excel Worksheet Functions 3 March 10th 10 11:56 PM
Finding content of cell in visible "protected" sheets RiverGully Excel Programming 4 October 5th 09 10:01 PM
Splitting out Content in 1 cell (which is currently separated by"ALT-ENTER") into multiple cells Sunil Ahuja Excel Discussion (Misc queries) 1 March 24th 09 05:27 PM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
Combining formulas, "and" & "or" to verify content of multiple cel Shu of AZ Excel Discussion (Misc queries) 15 October 15th 06 11:22 PM


All times are GMT +1. The time now is 04:06 PM.

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"