Blank Cell if next cell value is 0

D

Dervish

Hello:

Please help me with this one:

I like to have these cells:
A1: Blue
A2: 0
A3: Red
A4: 1
A5: Green
A6: 0
A7: Yellow
A8: 7

convert to these:
A1:
A2: 0
A3: Red
A4: 1
A5:
A6: 0
A7: Yellow
A8: 7

(if A2 value is 0 (zero), A1 should be blank and so on...

Thanks in advance.

Dervish
 
F

Frank Kabel

Hi
do you want a macro solution for this? or would be an output an an
adjancent column be sufficient?
 
D

Dave Peterson

How about this formula in B1:

=IF(AND(A2<>"",A2=0),"",A1)

And drag down.

If you want, you can select column B
Edit|copy,
edit|paste special|values

And delete column A.
 
D

Dervish

Sorry but the actual project is a bit more complicated. I need to
remove the colorant names in the example below if the value on the
adjacent cell is zero or blank. There are thousands of these in my
worksheet and it is not easy to delete them manually. Here is the
case:

From this:

A1: 2-1 Natural White
A2: Pastel Base - Quart
A3: Black B3: 21
A4: Yellow B4: 0
A5: Red B5: 36
A6: White B6: 0

To this:

A1: 2-1 Natural White
A2: Pastel Base - Quart
A3: Black B3: 21
A4: B4: 0
A5: Red B5: 36
A6: B6: 0

I would like to be able to remove Yellow in cell A4 and White in A6
because B4 and B6 values are 0 (zero.

Thanks in advance. Sorry about the confusion on my first post.
Dervish.
 
F

Frank Kabel

Hi
one manual way:
1. Apply Autofilter
2. Filter all zeros in column B
3. Select column A
4. Hit F5, click 'Special' and choose 'visible cells only'
5. Hit the dEL key
 
D

Dewi

On 29 Oct 2004 08:34:09 -0700, (e-mail address removed) (Dervish)
uttered:

Conditional format?

Format>conditional format
if A2 is equal too 0 then font white

The word will still be there, but won't show or if printed
 
D

Dervish

Thanks to ALL!!

I had to go back to the previous sheets and deleted all those cells
using sort option. I believe it was the most pain less way. I now have
to put all these cells back to the final format.

Regards,

Dervish
 

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

Top