ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   How do I make changes in all sheets within a workbook? (https://www.excelbanter.com/excel-worksheet-functions/38762-how-do-i-make-changes-all-sheets-within-workbook.html)

shfz

How do I make changes in all sheets within a workbook?
 
I have 2 columns in all (around 30) worksheets that are frozen how can I
unfreeze the panes. I can select all sheets within the workbook but if I
unfreeze the panes/columns in the one sheet it doesnt affect the other 29.
Anyone now how to? thanks.

Blue Hornet

Best way I know how to do this is with a macro. A simple one to do
what you want would be:

Option Explicit
Dim Counter As Integer
Dim StartSheet As String

Sub Unfreeze()
' First find where we're starting from
StartSheet = ActiveSheet.Name

' Step through sheets and unfreeze
For Counter = 1 To Worksheets.Count
Worksheets(Counter).Activate
ActiveWindow.FreezePanes = False
Next Counter

' Go back to the start point
Sheets(StartSheet).Activate
End Sub



All times are GMT +1. The time now is 04:26 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com