Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I freeze panes on a un-activated worksheet

Status
Not open for further replies.

xlStar

Technical User
Nov 16, 2003
55
GB
Worksheets("Sheet2").Activate
Range("I7").Select
ActiveWindow.FreezePanes = True

Why can't I use...

Worksheets("Sheet2").Range("I7").FreezePanes = True


The worksheet is Acitvate on Sheet1. YOu guys told me to reduced the "Select" and "Activate" method.
 
Reduce not eliminate. Sometimes you may have to use them.

regards Hugh
 

If you look in the help file (which you should always do before coming here) you will discover that the "FreezePanes" applies to the Window Object and not a Range Object.

Help File --> Search topic --> FreezePanes --> Click "Applies To" --> Read "Window Object"

The general admonition to reduce "Select" and "Activate" applies to worksheets and ranges, not windows.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top