
=SE(B1>MAX(A1:A25);"OK";"NO") =B1>MAX(A1:A25) per il si =B1 |
=SE(B1 maggiore MAX(A1:A25);"OK";"NO") =B1 maggiore MAX(A1:A25) per il si =B1 minore MAX(A1:A25) per il no |
option explicit
Public Function cfr_date(rng as range, d as date) as boolean
dim cell as range
for each cell in rng
if d > cdate(cell) then
cfr_date = true
exit function
end if
next
End Function |
Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Target, Range("B1")) Is Nothing Then Exit Sub
Application.EnableEvents = False
If Target > Application.Max(Range("A1:A" & Cells(Rows.Count, "A").End(xlUp).Row)) Then
MsgBox "Dato Maggiore OK"
Else
MsgBox "Dato Minore NON Valido"
End If
Application.EnableEvents = True
End Sub |
