Excel 2007/VBA Problem

  Chas49 22:27 07 Oct 10

I have cell containing a formula, this formula prints a total in the cell. I have after further processing to clear that cell of the content by means of VBA code, however, this wipes out the formula too.

Is there a way to clear the cell of its value but not the formula please?

  VoG II 22:49 07 Oct 10

No, a cell can contain a formula or a value but not both.

  Chas49 22:58 07 Oct 10

Thanks VoG™. So, would I be correct in thinking that the formula is automatically destroyed by the value obtained by it - that value being stored in the cell in which the formula was typed.

Thanks again - I'll have to think again!

  VoG II 09:31 08 Oct 10

You might just want to hide it by making the font white

Range("A1").Font.ColorIndex = 2

  Chas49 09:41 08 Oct 10

VoG™: Good Idea -why didn't I think of that! The odd thing is, VOG, that I have used that method on other occasions where a formula was not involved. Sometimes you just can't see the wood for the trees! Thanks again.

  KremmenUK 13:32 08 Oct 10

If I want to hide the contents of a cell I tend to set it's custom format to ";;;"

This thread is now locked and can not be replied to.

Nintendo Switch review: Hands-on with the intuitive modular console and its disappointing games…

1995-2015: How technology has changed the world in 20 years

This abstract video touches on division in our technologic world

Best alternatives to iTunes for Mac | Best music players for macOS: Free your music from the…