
Option Explicit
Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Target, Range("A:A")) Is Nothing Then Exit Sub
Dim cella
If Target.Cells.Count > 1 Then Exit Sub
If Cells(Target.Row, 1) = "" Then
Cells(1, 100) = Target.Row
End If
If Cells(Target.Row, 1) <> "" And IsNumeric(Cells(Target.Row, 1)) Then
If Target.Row > Cells(1, 100) Then
MsgBox ("+" & Target.Row - Cells(1, 100) & " Righe")
Else
MsgBox (Target.Row - Cells(1, 100) & " Righe")
End If
End If
End Sub |
