T
Tim
I'm having a problem with the calender control. It works
fine until I protect the sheet, then I get a run time error
'1004'.
When I hit debug, ActiveCell.NumberFormat = "dd-mmm-yy" is
hilighted in yellow.
Here is the code.
Private Sub Calendar1_DblClick()
ActiveCell.NumberFormat = "dd-mmm-yy"
ActiveCell = Calendar1.Value
End Sub
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Not Application.Intersect(Range("J9,J10,J11,BP4"),
Target) Is Nothing Then
Calendar1.Left = Target.Left + Target.Width -
Calendar1.Width
Calendar1.Top = Target.Top + Target.Height
Calendar1.Visible = True
Else: Calendar1.Visible = False
End If
End Sub
I'm using Excel 2003.
fine until I protect the sheet, then I get a run time error
'1004'.
When I hit debug, ActiveCell.NumberFormat = "dd-mmm-yy" is
hilighted in yellow.
Here is the code.
Private Sub Calendar1_DblClick()
ActiveCell.NumberFormat = "dd-mmm-yy"
ActiveCell = Calendar1.Value
End Sub
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Not Application.Intersect(Range("J9,J10,J11,BP4"),
Target) Is Nothing Then
Calendar1.Left = Target.Left + Target.Width -
Calendar1.Width
Calendar1.Top = Target.Top + Target.Height
Calendar1.Visible = True
Else: Calendar1.Visible = False
End If
End Sub
I'm using Excel 2003.