If Formula Help

N

natei6

Hi All,

=IF(SUM(H2:H4)>0,G2&" # "&H2&", "&G3&" # "&H3&", "&G4&" # "&H4,"Ente
Job Numbers On Cutsheet") This is the formula I am using right now. I
gives me these results: "Chip # 23, MDF # 24, 2 Side # 25". This work
Fine as long as H2:H4 all have a value greater than zero, but if one o
two of the cells are blank, I don't want the corrosponding info. Ho
do I write the formula to only show for example "Chip # 23" if H3:H
are blank. This is what I have tried so far, no success.

=IF(H2>0,G2&" # "&H2),IF(H3>0,G3&" # "&H3&", "))IF(H4>0,G4&"
"&H4))),"Enter Job Numbers On Cutsheet")


Any help appreciated

Nathan Sargean
 
D

Debra Dalgleish

The following formula checks for non-zero values, and inserts commas
where appropriate:

=IF(SUM(H2:H4)=0,"Enter Job Numbers On Cutsheet",IF(H2>0,G2&" # " &
H2 & IF(COUNTIF(H2:H4,">0")>1,", ",""),"") & IF(H3>0,G3&" # " & H3 &
IF(COUNTIF(H3:H4,">0")>1,", ",""),"")&IF(H4>0,G4&" # " & H4,""))
 
N

natei6

Debra,

Many Many Many Thanks!!! That's brilliant! It works just perfect.
I'm trying to educate myself and understand just exactly how what yo
did works. I have learned so much from this forum.

Thank Again,

Nathan Sargean
 
D

Debra Dalgleish

Nathan,

You're welcome! If there's something you can't figure out, post a
question, and someone should be able to help.

Debra
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top