#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,814
Default IF TYPE FUNCTION

I have office student 2003 excell. My problem is getting a single cell to be
examined for content and based what is in there will do one of many things.
ie cell 1 has "A" value and does "z work", if cell 1 has "B" value and does
"y work", if cell 1 has "C" value and does "x work" etc. "IF" statement will
only allow me to do a true or false with an excution. "OR" state will only
allow me to check the cell but not perform something else.
--
Steve
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 915
Default IF TYPE FUNCTION

Steve wrote:
I have office student 2003 excell. My problem is getting a single cell to be
examined for content and based what is in there will do one of many things.
ie cell 1 has "A" value and does "z work", if cell 1 has "B" value and does
"y work", if cell 1 has "C" value and does "x work" etc. "IF" statement will
only allow me to do a true or false with an excution. "OR" state will only
allow me to check the cell but not perform something else.


One way is to use nested IF statements:

=IF(A1="A",[z work],IF(A1="B",[y work],IF(A1="C",[x work],[default work])))

This construct has its limitations and can get a little tedious to code
and debug. Depending on your actual situation, there might be a better way.
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,814
Default IF TYPE FUNCTION


-- Thank you that looks like my answer. I'll have to check this out in the
morning.
You indicate that there maybe a different way what is it?
Steve


"smartin" wrote:

Steve wrote:
I have office student 2003 excell. My problem is getting a single cell to be
examined for content and based what is in there will do one of many things.
ie cell 1 has "A" value and does "z work", if cell 1 has "B" value and does
"y work", if cell 1 has "C" value and does "x work" etc. "IF" statement will
only allow me to do a true or false with an excution. "OR" state will only
allow me to check the cell but not perform something else.


One way is to use nested IF statements:

=IF(A1="A",[z work],IF(A1="B",[y work],IF(A1="C",[x work],[default work])))

This construct has its limitations and can get a little tedious to code
and debug. Depending on your actual situation, there might be a better way.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 915
Default IF TYPE FUNCTION

Not to be elusive, but it depends. Describe your real problem in more
detail and we can explore the options.

Steve wrote:
-- Thank you that looks like my answer. I'll have to check this out in the
morning.
You indicate that there maybe a different way what is it?
Steve


"smartin" wrote:

Steve wrote:
I have office student 2003 excell. My problem is getting a single cell to be
examined for content and based what is in there will do one of many things.
ie cell 1 has "A" value and does "z work", if cell 1 has "B" value and does
"y work", if cell 1 has "C" value and does "x work" etc. "IF" statement will
only allow me to do a true or false with an excution. "OR" state will only
allow me to check the cell but not perform something else.

One way is to use nested IF statements:

=IF(A1="A",[z work],IF(A1="B",[y work],IF(A1="C",[x work],[default work])))

This construct has its limitations and can get a little tedious to code
and debug. Depending on your actual situation, there might be a better way.

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,696
Default IF TYPE FUNCTION

If you have many possibilities, you may want to go with a VLOOKUP.

Create a table with your value list in, say, Sheet2, column A and your work
result in column B.

in your desired result cell, type =VLOOKUP(A2,Sheet2!A:B,2,0) to return the
B value.

"Steve" wrote:

I have office student 2003 excell. My problem is getting a single cell to be
examined for content and based what is in there will do one of many things.
ie cell 1 has "A" value and does "z work", if cell 1 has "B" value and does
"y work", if cell 1 has "C" value and does "x work" etc. "IF" statement will
only allow me to do a true or false with an excution. "OR" state will only
allow me to check the cell but not perform something else.
--
Steve

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
some type of IF function WHERE IS THE ANY KEY???? Excel Worksheet Functions 2 September 15th 08 08:57 PM
TYPE function Iriemon Excel Worksheet Functions 3 August 8th 08 02:43 PM
NVL type function Jonathan Excel Worksheet Functions 5 May 16th 06 07:58 PM
Help with TYPE function DMDave Excel Discussion (Misc queries) 5 May 7th 06 06:38 PM
I need a productif type function Mitch Excel Discussion (Misc queries) 5 May 4th 06 05:33 PM


All times are GMT +1. The time now is 07:20 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"