I'm creating a document in excel that needs specific information copied from columns and pasted ntot a specific range. The problem I'm having is that it's copying blanks and duplicate information from the cells and it's putting it outside my range. I would like to remove the blanks and duplicate values and keep all information within my "Panels" range. My "Panels" range is from AZ95:BM104 respectively. Here's the code I currently have.
Any help is greatly appreciated.![]()
Sub Marco1 () Range("S2:AV100").Select 'Selection range that I'm copying is S2:AV100 Selection.Copy Range ("Panels").Select 'Range pasting to is panels Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks:= _ False, Transpose:=True 'Special Paste values only Application.CutCopyMode = False Activesheet.Range("Panels").RemoveDuplicates Column:=Array(1,2), Header:=xlNo 'Remove all duplicate values this doesn't work End Sub
Bookmarks