Hi Everyone. I need to run a macro ("ReformatData") everytime that someone adds or changes data in a table. So far I have the code below in the VBA project box (Excel 2010) which only works when I "manually" select a cell and change the data, but not when I right click to insert new data or operate "control V" to paste new data over old (which is 99% of the time)
Could any one suggest a code which will run the macro when data is pasted, inserted or "manually" changed but NOT when a superficial alteration is made such as colour formatting or using the automatic filters? Thanks in advance for giving this some thought.
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Count > 1 Then Exit Sub
If Not Intersect(Target, Range("$A$31:$L$10000")) Is Nothing Then
Call ReformatData
Range("A1").Select
MsgBox "Reformaté"
End If
End Sub
Bookmarks