Worksheet_change event is used.Pl see file.
K5 Validated cell, M5 is the destination cell.
If M5 is not having the value of K5, then pnly it will add. This avoids duplication.
code
![]()
Private Sub Worksheet_Change(ByVal Target As Range) If Target.Address = "$K$5" Then Application.EnableEvents = False If InStr(1, Range("M5"), Range("K5")) = 0 Then Range("M5") = Range("M5") & "," & Range("K5") End If Application.EnableEvents = True End If End Sub
Bookmarks