why does this macro select the entire worksheet when run?
Ah, thanks.
Dave
--
A hint to posters: Specific, detailed questions are more likely to be
answered than questions that provide no detail about your problem.
"Dave Peterson" wrote:
If you activate a cell in the current selection, it doesn't change the
selection. It just changes the activecell.
Range("B1").select
would change the selection to just B1.
Dave F wrote:
Here's the macro:
Sub UnhideAll()
'Unhides all rows
'Freezes window at E4
Cells.Select
Range("B1").Activate
Selection.EntireRow.Hidden = False
Selection.EntireColumn.Hidden = False
Range("E4").Activate
ActiveWindow.FreezePanes = False
ActiveWindow.FreezePanes = True
End Sub
Dave
--
A hint to posters: Specific, detailed questions are more likely to be
answered than questions that provide no detail about your problem.
--
Dave Peterson
|