View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
joel joel is offline
external usenet poster
 
Posts: 9,101
Default Automate Tab Color

Add code to thisworkbook page in VBA window

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, _
Cancel As Boolean)

For Each ws In Sheets
Sheets(ws.Name).Tab.ColorIndex = 3
Next ws
End Sub


"Bob" wrote:

hello-

I'd like to make a macro that changes all tabs to red when the file is Saved
As somethings else. Once they are "reset" in a save as mode, they are free
to be changed manually, I just would like to have a script that defaults a
new file to red tabs.

Does anyone on this list have any suggestions of a short script?

regards,
-b o b