#1
|
|||
|
|||
Copy colored cells to new worksheet (maintain cell position)
I have a worksheet with many columns and rows. I have colored coded certain rows. Please provide code that would enable me to transfer the highlighted rows from the current worksheet to another worksheet within the same workbook. |
#2
|
|||
|
|||
Hopefully this will get you started in the right direction.
vba - Copy paste entire row if the cell has red/green/Yellow color in excel - Stack Overflow |
#3
|
|||
|
|||
How about somthing like this?
Code:
Sub MoveColours() Worksheets("Sheet1").Range("a1").CurrentRegion.Copy Worksheets.Add.Name = "Output" Worksheets("Output").Range("a1").PasteSpecial xlPasteAll Range("a1").AutoFilter Field:=1, Operator:=xlFilterNoFill Application.DisplayAlerts = False Range("a1").CurrentRegion.Offset(1, 0).SpecialCells(xlCellTypeVisible).Delete Application.DisplayAlerts = True ActiveSheet.AutoFilterMode = False End Sub |
Tags |
copy cells |
Thread Tools | |
Display Modes | |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Looking to copy select cells in table using dropdown list to paste to new table in another worksheet | CaptainRetired | Excel Programming | 18 | 01-04-2018 07:22 PM |
Copy a cell's contents across many cells | cloa513 | Word Tables | 13 | 09-19-2016 11:11 PM |
copy cells from a worksheet into other worksheets based on Criteria | Elton Wolter | Excel Programming | 4 | 04-16-2016 08:44 AM |
Looping through rows and copy cell values to another worksheet | get4hari | Excel Programming | 1 | 10-02-2015 04:51 PM |
Can you copy & paste cells across worksheets and preserve reference to worksheet? | New Daddy | Excel | 2 | 11-27-2013 07:19 AM |