Changes only

thorpyuk

Well-known Member
Joined
Mar 14, 2006
Messages
1,453
Hiya,

I have a spreadsheet that you can enter customer details onto. I can 'import' these details by using a search, and then change them at will.

The one problem is that I wish to export changes into a sheet called 'export'

Therein lies the problem..... I can easily enough just copy everything into the export spreadsheet, but then I can forsee the conversation approaching: "cant you just give us what has changed?"

Now, i've seen a few macros that can either add comments to a cell, or add text to an adjecant cell if anything changes, but these are no good for me for 2 reasons:

1) I use a macro to import into the sheet in the first place, and this constitues several change events in the worksheet_change module.
2) I would then need to easily export the changes, and I dont see me being able to do this easily given the method above.

Please can anyone point me in the right direction? I'm not necessarily looking for code, but any ideas you may have would be great! Thanks
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Here's the form that the data is imported into. I want to bring the changes into a basic export sheet (where the data will be a lot more linear)

sample.jpg
 
Upvote 0
The user can change any of the fields in the picture above.... is that what you mean?
 
Upvote 0
Not sure if this is what you wanted
to a sheet module
Code:
Private OldData(1)

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
OldData(0) = OldData(1)
OldData(1) = Target.Value
End Sub

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Count > 1 Then
     With Application
          .EnableEvents = False
          .Undo
          .EnableEvents = True
     End With
     Exit Sub
End If
If Target.Value <> OldData(0) Then
     Application.EnableEvents = False
     Target.Offset(,1).Value = "Was : " & OldData(0) & ", Now : " & Target.Value
     Application.EnableEvents = True
End If
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,386
Messages
6,119,214
Members
448,874
Latest member
b1step2far

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top