A way to auto insert at top of each column with each entry?
Hi Channing,
Does this Worksheet_Change event procedure do what you want?...
Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Target, Range("A1:D1")) Is Nothing Then
Application.EnableEvents = False
Dim rngCell As Range
For Each rngCell In Target
Cells(IIf(rngCell.End(xlDown).Row = _
Columns(rngCell.Column).Rows.Count, _
2, rngCell.End(xlDown).Row + 1), rngCell.Column).Value _
= rngCell.Value
rngCell.ClearContents
Next
Application.EnableEvents = True
End If
End Sub
If you type or paste values into A1:D1 they are cut and pasted into the
next available cell at the bottom of the same column.
Copy and paste the code into the worksheet's code module.
Ken Johnson
|