![]() |
Code to conditional format all black after date specified in code?
I have a date in cell A100 sheet 1
Can anyone provide a code that will conditionally format an entire sheet (sheet2) to black fill and font if now() is greater than date in cell A1? Or perhaps change sheet 2 to Very Hidden. |
Code to conditional format all black after date specified in code?
Try this Private Sub Worksheet_Change(ByVal Target As Range) If Now() Sheet1.Range("A100") Then Sheet2.Visible = xlSheetVeryHidden Else Sheet2.Visible = xlSheetVisible End If End Sub -- mikeaj72 ------------------------------------------------------------------------ mikeaj72's Profile: http://www.thecodecage.com/forumz/member.php?userid=46 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=44333 |
Code to conditional format all black after date specified in code?
One way:
Select all cells in sheet2. Choose Format/Conditional Formatting: CF1: = $A$1 < NOW() Format1: <pattern/<black, <font/<black Note that this will not prevent one from seeing the formula/value in the formula bar. The user will also be able to, say, on another sheet, enter A1: =Sheet2!A1 and copy down and across, revealing the values. In article , wx4usa wrote: Can anyone provide a code that will conditionally format an entire sheet (sheet2) to black fill and font if now() is greater than date in cell A1? |
Code to conditional format all black after date specified incode?
On Dec 26, 12:37*pm, JE McGimpsey wrote:
One way: Select all cells in sheet2. Choose Format/Conditional Formatting: CF1: * * = $A$1 < NOW() Format1: <pattern/<black, <font/<black Note that this will not prevent one from seeing the formula/value in the formula bar. The user will also be able to, say, on another sheet, enter A1: * * *=Sheet2!A1 and copy down and across, revealing the values. In article , *wx4usa wrote: Can anyone provide a code that will conditionally format an entire sheet (sheet2) to black fill and font if now() is greater than date in cell A1? Thanks, that worked! |
All times are GMT +1. The time now is 06:04 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com