View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Antonio
 
Posts: n/a
Default When to Activate?

The following works fine

Worksheets("EQ by P").Rows((number_s+ 4) & ":" & (number_ + 3)).ClearContents

The following does not (one line)
Worksheets("pivot").Range(Cells(number_s + 3, 1), Cells(number_ + 2,
5)).ClearContents

The following does (two lines):
Worksheets("pivot").Activate

Range(Cells(number_s + 3, 1), Cells(number_ + 2, 5)).ClearContents

Why is that?

When is "Activate" required?



Why is the following not working?