Attached below is a sheet that will show what I am talking about here. But this is what I am looking for. As you can see in sheet in Final shows all the list in a nice neat order.
This is what the end user sees. Now in some cases when a document like the Orig is sent to me, I need to import new lines if there are any. What I have been noticing though is that although the line are almost completely the same the client comments are different.
And with how comments are entered in red by us on the Final sheet, I just can’t copy and replace everything. What I want to do is replace only the client comments and the required ship date.
I’d like to refrence the PO, the Part, and the Description as refrence points, and then replace the client comments and the required ship date with the new one, even if there isn’t a change, I still would like to have it replaced as a just in case senario.
Can someone show me a script in VBA that will do that?
I thought about using something like this to do it:
With Intersect(wsJL.UsedRange, wsJL.Columns("Q"))
.AutoFilter 1, "<>Same"
With Intersect(.Offset(2).EntireRow, .Parent.Range("B:U"))
.Copy wsJAR.Cells(Rows.Count, "B").End(xlUp).Offset(1)
.EntireRow.Delete
End With
.AutoFilter
End With
But I am running into an issue where this isn’t an EntireRow concept, but two individual cells not together, otherwise it would be a lot easier for me.
Is there a way of using this script or another one like it to get the results I am looking for?
Thanks for your help in advance if you can offer any.
Solved it.
Did something a little different, not how I wanted, but it’s the easiest answer. Added two cells at the end of the data of the final tab:
For O2-O4
=IFERROR(INDEX(Orig!$J$2:$J$4,MATCH(1,INDEX((Orig!$B$2:$B$4=$A2)*(Orig!$D$2:$D$4=$B2),0),0)),"")For P2-P4
=IFERROR(INDEX(Orig!$E$2:$E$4,MATCH(1,INDEX((Orig!$B$2:$B$4=$A2)*(Orig!$D$2:$D$4=$B2),0),0)),"")and then created a new script:
It works, but I was hoping for something a little cleaner. Here is the end result.
Solution