D
David Lipetz
Folks,
I am completely new to the whole Excel macro/VBA world, though I am pretty
spiffy when in comes to Excel.
By using lots of Google, I have put together the VBA macro below that
actually does work. However, I would like to add code so that the AutoFilter
custom parameters are set by default to: Custom, Is Greater Than, 0.
How can I accomplish this within this code:
Private Sub Worksheet_Change(ByVal Target As Range)
With Target
If .Count > 1 Then Exit Sub
If Not Intersect(Range("C7"), .Cells) Is Nothing Then
Application.EnableEvents = False
ActiveSheet.Unprotect
With .Offset(0, 2)
.NumberFormat = "mmmm d, yyyy"
.Value = Date
End With
ActiveSheet.EnableAutoFilter = True
ActiveSheet.Protect contents:=True, userInterfaceOnly:=True
Application.EnableEvents = True
End If
End With
End Sub
Thanks in advance.
David
I am completely new to the whole Excel macro/VBA world, though I am pretty
spiffy when in comes to Excel.
By using lots of Google, I have put together the VBA macro below that
actually does work. However, I would like to add code so that the AutoFilter
custom parameters are set by default to: Custom, Is Greater Than, 0.
How can I accomplish this within this code:
Private Sub Worksheet_Change(ByVal Target As Range)
With Target
If .Count > 1 Then Exit Sub
If Not Intersect(Range("C7"), .Cells) Is Nothing Then
Application.EnableEvents = False
ActiveSheet.Unprotect
With .Offset(0, 2)
.NumberFormat = "mmmm d, yyyy"
.Value = Date
End With
ActiveSheet.EnableAutoFilter = True
ActiveSheet.Protect contents:=True, userInterfaceOnly:=True
Application.EnableEvents = True
End If
End With
End Sub
Thanks in advance.
David