Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
copy all but formula to next empty column
I have a data entry sheet, to begin with data can only be entered into the
range G5:H59(some of the cells are merged). I want to be able to search for the next empty cell, along row 5 then copy all the formating calculations and data validation from G5:H59 to the avalible column. Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
copy all but formula to next empty column
Try this code
Sub CopyFormat() For RowCount = 5 To 59 If Range("G" & RowCount) < "" Then LastCol = Cells(RowCount, Columns.Count).End(xlToLeft).Column Range("G" & RowCount).Copy Cells(RowCount, LastCol + 1).PasteSpecial _ Paste:=xlPasteFormats, _ Paste:=xlPasteValidation End If Next RowCount End Sub "Miree" wrote: I have a data entry sheet, to begin with data can only be entered into the range G5:H59(some of the cells are merged). I want to be able to search for the next empty cell, along row 5 then copy all the formating calculations and data validation from G5:H59 to the avalible column. Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Find first empty cell in column J. Copy, paste special, value from | Excel Programming | |||
How to copy data to the next empty cell in a column | Excel Worksheet Functions | |||
copy content to first empty cell in column | Excel Programming | |||
Copy from row above if cell is empty in column | Excel Discussion (Misc queries) | |||
Copy a value to the next empty cell in a column | Excel Programming |