This was a serious challenge to me: I need to have the tab colour
changed automatically if data is entered in a certain range in a
spreadsheet with many worksheets, so I do not have to go through every
worksheet every week to see if data was entered. Is this possible?
Thank you,
Calin Alexandrescu
Project Manager--
calin
------------------------------------------------------------------------
calin's Profile: www.excelforum.com/member.php...oamp;userid=29265
View this thread: www.excelforum.com/showthread...hreadid=526731You can use a workbook event:
Option Explicit
Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
Dim myAddrToCheck As String
myAddrToCheck = quot;A1:C9quot;
If Intersect(Sh.Range(myAddrToCheck), Target) Is Nothing Then
Exit Sub
Else
Sh.Tab.ColorIndex = 3
End If
End SubThis goes behind the ThisWorkbook module.
If you're new to macros, you may want to read David McRitchie's intro at:
www.mvps.org/dmcritchie/excel/getstarted.htm
If you want to read more about these kinds of events:
Chip Pearson's site:
www.cpearson.com/excel/events.htm
David McRitchie's site:
www.mvps.org/dmcritchie/excel/event.htm
calin wrote:
gt;
gt; This was a serious challenge to me: I need to have the tab colour
gt; changed automatically if data is entered in a certain range in a
gt; spreadsheet with many worksheets, so I do not have to go through every
gt; worksheet every week to see if data was entered. Is this possible?
gt;
gt; Thank you,
gt; Calin Alexandrescu
gt; Project Manager
gt;
gt; --
gt; calin
gt; ------------------------------------------------------------------------
gt; calin's Profile: www.excelforum.com/member.php...oamp;userid=29265
gt; View this thread: www.excelforum.com/showthread...hreadid=526731
--
Dave Peterson
- Jul 25 Fri 2008 20:45
Automatically change tab colour
close
全站熱搜
留言列表
發表留言