Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default If then, adding more choices

I am using the following command to direct what happens in column of cells:
=IF(A6=1, E6*D3, IF(A6=2, E6*E3))

This works fine for 2 options, but when I try to add a 3rd & 4th, I get an
error.
=IF(A6=1, E6*D3, IF(A6=2, E6*E3), IF(A6=3, E6*F3), IF(A6=4, E6*G3))))
How do I add more options? I know my parenthesis and probably more are off.

Thanks!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 638
Default If then, adding more choices

You have too many parenthesis.
=IF(A6=1, E6*D3, IF(A6=2, E6*E3, IF(A6=3, E6*F3, IF(A6=4, E6*G3))))
sandygiz wrote:
I am using the following command to direct what happens in column of cells:
=IF(A6=1, E6*D3, IF(A6=2, E6*E3))

This works fine for 2 options, but when I try to add a 3rd & 4th, I get an
error.
=IF(A6=1, E6*D3, IF(A6=2, E6*E3), IF(A6=3, E6*F3), IF(A6=4, E6*G3))))
How do I add more options? I know my parenthesis and probably more are off.

Thanks!


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 12
Default If then, adding more choices

This seems to work:
=IF(A6=1, E6*D3, IF(A6=2, E6*E3, IF(A6=3, E6*F3, IF(A6=4, E6*G3))))

Ie, you dont use a closing bracket after each if argument, you just put a
closing bracket for each if argument at the end of the formula


Philip


"sandygiz" wrote in message
...
I am using the following command to direct what happens in column of cells:
=IF(A6=1, E6*D3, IF(A6=2, E6*E3))

This works fine for 2 options, but when I try to add a 3rd & 4th, I get an
error.
=IF(A6=1, E6*D3, IF(A6=2, E6*E3), IF(A6=3, E6*F3), IF(A6=4, E6*G3))))
How do I add more options? I know my parenthesis and probably more are
off.

Thanks!


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 857
Default If then, adding more choices

maybe like this:

=IF(A6=1, E6*D3, IF(A6=2, E6*E3, IF(A6=3, E6*F3, IF(A6=4, E6*G3))))


--
Hope that helps.

Vergel Adriano


"sandygiz" wrote:

I am using the following command to direct what happens in column of cells:
=IF(A6=1, E6*D3, IF(A6=2, E6*E3))

This works fine for 2 options, but when I try to add a 3rd & 4th, I get an
error.
=IF(A6=1, E6*D3, IF(A6=2, E6*E3), IF(A6=3, E6*F3), IF(A6=4, E6*G3))))
How do I add more options? I know my parenthesis and probably more are off.

Thanks!

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default If then, adding more choices

Thank you so much!!

"Philip Reece-Heal" wrote:

This seems to work:
=IF(A6=1, E6*D3, IF(A6=2, E6*E3, IF(A6=3, E6*F3, IF(A6=4, E6*G3))))

Ie, you dont use a closing bracket after each if argument, you just put a
closing bracket for each if argument at the end of the formula


Philip


"sandygiz" wrote in message
...
I am using the following command to direct what happens in column of cells:
=IF(A6=1, E6*D3, IF(A6=2, E6*E3))

This works fine for 2 options, but when I try to add a 3rd & 4th, I get an
error.
=IF(A6=1, E6*D3, IF(A6=2, E6*E3), IF(A6=3, E6*F3), IF(A6=4, E6*G3))))
How do I add more options? I know my parenthesis and probably more are
off.

Thanks!





  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default If then, adding more choices

=E6*CHOOSE(A6,D3,E3,F3,G3)

Tim

"Vergel Adriano" wrote in message
...
maybe like this:

=IF(A6=1, E6*D3, IF(A6=2, E6*E3, IF(A6=3, E6*F3, IF(A6=4, E6*G3))))


--
Hope that helps.

Vergel Adriano


"sandygiz" wrote:

I am using the following command to direct what happens in column of
cells:
=IF(A6=1, E6*D3, IF(A6=2, E6*E3))

This works fine for 2 options, but when I try to add a 3rd & 4th, I get
an
error.
=IF(A6=1, E6*D3, IF(A6=2, E6*E3), IF(A6=3, E6*F3), IF(A6=4, E6*G3))))
How do I add more options? I know my parenthesis and probably more are
off.

Thanks!



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
Choices Baffled[_2_] Excel Discussion (Misc queries) 1 September 29th 08 10:01 PM
=if with multiple choices 4Proffit Excel Worksheet Functions 1 March 28th 06 05:50 PM
Choices for User Disconer Excel Worksheet Functions 0 October 28th 05 06:31 PM
Book choices Orin Excel Programming 2 December 22nd 04 03:20 PM
Choices [email protected] Excel Worksheet Functions 0 December 21st 04 12:07 AM


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