Changed or Updated property?
Sorry,
First reply is wrong. Use This instead:
You should use another sheet to store the data
Private Sub Worksheet_Change(ByVal Target As Range)
Sheet2.Range("a1").Value = True
End Sub
Private Sub Worksheet_Deactivate()
If Sheet2.Range("a1").Value Then
MsgBox "Sheet has been changed"
Sheet2.Range("a1").Value = False
Else
End If
End Sub
"Excelerate-nl" wrote:
Hi Stefi,
This may work, but you have to use an intermediate cell somewhere to store
the status of the sheet:
(macro's in sheet1)
Private Sub Worksheet_Change(ByVal Target As Range)
Sheet1.Range("a1").Value = True
End Sub
Private Sub Worksheet_Deactivate()
If Sheet1.Range("a1").Value Then
MsgBox "Sheet has been changed"
Else
End If
End Sub
Regards,
Excelerate
Jan Bart
"Stefi" wrote:
Hi All,
Is there any way to check if any cells in a worksheet has been changed? I
want to use a Worksheet_Deactivate() event, but only if there was a change in
the sheet to avoid lengthy processing.
Thanks,
Stefi
|