nick612hayden
New Member
- Joined
- May 15, 2012
- Messages
- 33
hey all
does anyone see why this code won't loop to the next open workbook...? it only does it on the current workbook ive selected, and therefore, cannot Call to another macro...
ideally, i would rather just have all sheets in all open workbooks autofit from columns "B:Z" but that hasn't worked either, any help is appreciated!
Sub Adjust_Column_Specific()
Dim wBook As Workbook
Dim wSheet As Worksheet
Application.ScreenUpdating = False
For Each wBook In Workbooks
Sheets("Self").Select
Columns("B:Z").AutoFit
Sheets("Employee Backup").Select
Columns("B:Z").AutoFit
Sheets("Employee Calcs").Select
Columns("B:Z").AutoFit
Next wBook
Application.ScreenUpdating = True
End Sub
Thanks!
Nick
does anyone see why this code won't loop to the next open workbook...? it only does it on the current workbook ive selected, and therefore, cannot Call to another macro...
ideally, i would rather just have all sheets in all open workbooks autofit from columns "B:Z" but that hasn't worked either, any help is appreciated!
Sub Adjust_Column_Specific()
Dim wBook As Workbook
Dim wSheet As Worksheet
Application.ScreenUpdating = False
For Each wBook In Workbooks
Sheets("Self").Select
Columns("B:Z").AutoFit
Sheets("Employee Backup").Select
Columns("B:Z").AutoFit
Sheets("Employee Calcs").Select
Columns("B:Z").AutoFit
Next wBook
Application.ScreenUpdating = True
End Sub
Thanks!
Nick