View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jacob Skaria Jacob Skaria is offline
external usenet poster
 
Posts: 8,520
Default autoresize of cells (height)

Why dont you try hiding this rather resizing

Rows("2:2").EntireRow.Hidden = True

--
If this post helps click Yes
---------------
Jacob Skaria


"TG" wrote:

Hello,

I am trying "hide" a given amount of cells, for example I would like to
"hide" cells C5,D5,E5..etc.. if there is nothing in them. Lets say that I
have something like: =if(C1="X","hello","") and lets assume that this if
statement is in C5. Now if i wrote the if statement correctly.. if C1 has an
x then C5 will show "hello" but if it is empty then it will show nothing and
i want this whole row to be given a minimal height so they "hide". I
presently have a macro that will hide the rows if there is nothing in them
and then show them up again once there is something in them, the problem is
that it takes a large amount of time for the worksheet to update.

do you guys have any suggestions?

Thanks in advance.