If and then functions

  • Thread starter Thread starter kentf
  • Start date Start date
K

kentf

I have tried several ways with no success.
Here is what I am trying to do....
if g4 is greater >0 then multiply PRODUCT(E4,G4),
otherwise value = 0

How can I build this formula to work?
 
Hi Kentf!

Try:

=IF(G4>0,E4*G4,0)

IF functions have the syntax:

=IF(logical_test,value_if_true,value_if_false)

logical_test: Any value or expression that can be evaluated to TRUE or
FALSE
value_if_true: The value that is returned if logical_test is TRUE
value_if_false: (Optional) The value that is returned if logical_test
is FALSE

--
Regards
Norman Harker MVP (Excel)
Sydney, Australia
(e-mail address removed)
Excel and Word Function Lists (Classifications, Syntax and Arguments)
available free to good homes.
 
I have tried several ways with no success.
Here is what I am trying to do....
if g4 is greater >0 then multiply PRODUCT(E4,G4),
otherwise value = 0

How can I build this formula to work?


=IF(G4>0,PRODUCT(E4,G4),0)

or

=IF(G4>0,E4*G4,0)

or
=(G4>0)*E4*G4


--ron
 
-----Original Message-----
I have tried several ways with no success.
Here is what I am trying to do....
if g4 is greater >0 then multiply PRODUCT(E4,G4),
otherwise value = 0

How can I build this formula to work?
.
=IF(G4>0,G4*E4,"Zero")
 
Back
Top