filteredDups -not Working

Rayne used Ask the Experts™

When I deleted an empty column before B, now on changing values for the colored columns – it doesn’t work – Can you explain? Because of the column deletion from sheet [mainViewSheet] – Please assist. In real world, the source worksheet and the mainviewsheet may not have the same column structure and number exactly.

Thank you
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Try this

Private Sub Worksheet_Change(ByVal Target As Range)
Dim sr As Long, mr As Long, mc As Long, sc As Long
If Target.Count > 1 Then Exit Sub
If Target.Column - [mainresults].Column <> 2 And Target.Column - [mainresults].Column <> 3 Then Exit Sub
mr = Target.Row
mc = [mainresults].Column + 6
sc = Sheets("Source").Range("sourcerange").Resize(, 1).Offset(, 6).Column
sr = Sheets("Source").Cells(1, sc).EntireColumn.Find(Cells(mr, mc), , xlValues).Row
'Sheets("Source").Cells(Sheets("Source").Range("I:I").Find(Cells(sr, "I")).Row, Target.Column) = Target.Value
Sheets("Source").Cells(sr, Target.Column - mc + sc) = Target.Value

End Sub

Open in new window


Hi Ssaqibh,

Awesome. This one works dynamically to account for the columns. Perfect!! I will follow up with questions on this a little later. Please reply then.

Thank You

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial