- Nov 14, 2005
I want to run a check before the user leaves the tab.
I want it to run when the user leaves the tab, but I am assuming "Deactivate" isn't what I think it is because its not working when I leave the tab. The code works if I run it. Is there a way to run this when they leave the tab?
Private Sub Worksheet_Deactivate() ' Range("D1").Select ActiveCell.FormulaR1C1 = "=SUMIF(C,""parent"",C)" Range("D1").Select ' If Application.Range("D1") > 0 Then MsgBox "You or Someone has entered estimated hours/dollars against a PARENT WBS Task. Parent level WBS Tasks are Sumary level items. There should never be estimate directly bid to a Parent." ' Range("D1").Clear ' End Sub