Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 38
Default Logical if more than 7

A B C D
E F

1 shape of bar a b c formula required
2 BB
3 TB
4 S
5 L
6 SB
7 Z
8 ST
9 CH
10 SCB1
11 SCB2
12 HR


I WANT THE FORMULA IN F2 IF B2=BB OR TB OR S OR SB OR Z OR SCB1 OR SCB2
THEN F2= C2+D2+E2 THEN , IF B2=ST THEN F2=2*( C2+D2+E2) ,IF B2=TB THEN
C2+D2+E2, IF B2=HR THEN F2= 8*A+2*B.
PLEASE DO THE NEEDFUL.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,856
Default Logical if more than 7

In future, please do not SHOUT.

Put this formula in F2:

=IF(ISNA(MATCH(B2,B3:B13,0)),"not valid",IF(B2="ST",
2*(C2+D2+E2),IF(B2="HR",8*C2+2*D2,C2+D2+E2)))

You didn't have a condition for B2="CH" - this assumes C2+D2+E2.

Hope this helps.

Pete

On Jul 25, 4:10*pm, vmohan1978
wrote:

* * *A * * * * * * * * B * * * * * * * * * * * * * *C * * * * * *D * * * * * *
* * E * * * * * * * * * * * * * * * F

* * *1 *shape of bar * *a * * * b * * * c * * * formula required
*2 * * *BB * * * * * * * * * * * * * * *
* * 3 * TB * * * * * * * * * * * * * * *
* * 4 * S * * * * * * * * * * * * * * *
* * 5 * L * * * * * * * * * * * * * * *
* *6 * *SB * * * * * * * * * * * * * * *
*7 * * *Z * * * * * * * * * * * * * * *
* * 8 * ST * * * * * * * * * * * * * * *
9 * * * CH * * * * * * * * * * * * * * *
10 * * *SCB1 * * * * * * * * * * * * * *
11 * * *SCB2 * * * * * * * * * * * * * *
12 * * *HR * * * * * * * * * * * * * * *

I WANT THE FORMULA *IN F2 *IF B2=BB OR TB OR S OR SB OR Z OR SCB1 OR SCB2
THEN F2= C2+D2+E2 THEN *, IF B2=ST THEN F2=2*( C2+D2+E2) ,IF B2=TB THEN
C2+D2+E2, IF B2=HR THEN F2= 8*A+2*B.
PLEASE DO THE NEEDFUL.


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default Logical if more than 7

=IF(OR(B2={"BB","TB","S","SB","Z","SCB1","SCB2"}), SUM(C2:E2),IF(B2="ST",2*SUM(C2:E2),IF(B2="HR",8*A+ 2*B,0)))

What is "A" and "B" in your last formula?


"vmohan1978" wrote:

A B C D
E F

1 shape of bar a b c formula required
2 BB
3 TB
4 S
5 L
6 SB
7 Z
8 ST
9 CH
10 SCB1
11 SCB2
12 HR


I WANT THE FORMULA IN F2 IF B2=BB OR TB OR S OR SB OR Z OR SCB1 OR SCB2
THEN F2= C2+D2+E2 THEN , IF B2=ST THEN F2=2*( C2+D2+E2) ,IF B2=TB THEN
C2+D2+E2, IF B2=HR THEN F2= 8*A+2*B.
PLEASE DO THE NEEDFUL.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,358
Default Logical if more than 7

With only 1 IF Statement. Further clarification on what is A or B in the
formula if B2="HR".

=(B2="HR")*(8*A+2*B)+SUM(C2:E2)*IF(B2="ST",2,OR(B2 ={"BB","TB","S","SB","Z","SCB1","SCB2"}))


--
John C


"vmohan1978" wrote:

A B C D
E F

1 shape of bar a b c formula required
2 BB
3 TB
4 S
5 L
6 SB
7 Z
8 ST
9 CH
10 SCB1
11 SCB2
12 HR


I WANT THE FORMULA IN F2 IF B2=BB OR TB OR S OR SB OR Z OR SCB1 OR SCB2
THEN F2= C2+D2+E2 THEN , IF B2=ST THEN F2=2*( C2+D2+E2) ,IF B2=TB THEN
C2+D2+E2, IF B2=HR THEN F2= 8*A+2*B.
PLEASE DO THE NEEDFUL.

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 38
Default Logical if more than 7

HI,
Thank you very much it worked perfectly, and saved lot of my time.
For HR it should be 8*c2+2*d2

"Teethless mama" wrote:

=IF(OR(B2={"BB","TB","S","SB","Z","SCB1","SCB2"}), SUM(C2:E2),IF(B2="ST",2*SUM(C2:E2),IF(B2="HR",8*A+ 2*B,0)))

What is "A" and "B" in your last formula?


"vmohan1978" wrote:

A B C D
E F

1 shape of bar a b c formula required
2 BB
3 TB
4 S
5 L
6 SB
7 Z
8 ST
9 CH
10 SCB1
11 SCB2
12 HR


I WANT THE FORMULA IN F2 IF B2=BB OR TB OR S OR SB OR Z OR SCB1 OR SCB2
THEN F2= C2+D2+E2 THEN , IF B2=ST THEN F2=2*( C2+D2+E2) ,IF B2=TB THEN
C2+D2+E2, IF B2=HR THEN F2= 8*A+2*B.
PLEASE DO THE NEEDFUL.



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 38
Default Logical if more than 7

Hi John,
Thanks lot you have saved my lot of time , this is your 2nd answe for my
problem . Thank you very much

"John C" wrote:

With only 1 IF Statement. Further clarification on what is A or B in the
formula if B2="HR".

=(B2="HR")*(8*A+2*B)+SUM(C2:E2)*IF(B2="ST",2,OR(B2 ={"BB","TB","S","SB","Z","SCB1","SCB2"}))


--
John C


"vmohan1978" wrote:

A B C D
E F

1 shape of bar a b c formula required
2 BB
3 TB
4 S
5 L
6 SB
7 Z
8 ST
9 CH
10 SCB1
11 SCB2
12 HR


I WANT THE FORMULA IN F2 IF B2=BB OR TB OR S OR SB OR Z OR SCB1 OR SCB2
THEN F2= C2+D2+E2 THEN , IF B2=ST THEN F2=2*( C2+D2+E2) ,IF B2=TB THEN
C2+D2+E2, IF B2=HR THEN F2= 8*A+2*B.
PLEASE DO THE NEEDFUL.

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
Logical Angeline Excel Discussion (Misc queries) 1 December 13th 07 05:57 AM
Logical Functions Eden397 Excel Worksheet Functions 3 June 11th 07 04:08 PM
Logical Functions Eden397 Excel Worksheet Functions 10 June 11th 07 04:06 PM
Logical Value At A Loss Excel Worksheet Functions 7 March 13th 06 04:42 PM
SUM for logical values tjtjjtjt Excel Discussion (Misc queries) 6 November 16th 05 01:30 AM


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