ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   using fill handle with hidden rows (https://www.excelbanter.com/excel-discussion-misc-queries/151017-using-fill-handle-hidden-rows.html)

Shazzer

using fill handle with hidden rows
 
When I use the fill handle to copy something down to a new row, the hidden
rows in between are also filled in. Is there any way I can stop this so that
it only copies to the rows that are showing? Thank you.

Don Guillett

using fill handle with hidden rows
 

One way to copy a8 to visible in a9:a20

Sub CopyToVisibleCellsOnly()
For Each c In Range("a9:a20")
If c.Rows.Hidden = False Then Range("a8").Copy c
Next
End Sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Shazzer" wrote in message
...
When I use the fill handle to copy something down to a new row, the hidden
rows in between are also filled in. Is there any way I can stop this so
that
it only copies to the rows that are showing? Thank you.



Shazzer

using fill handle with hidden rows
 
Thank you Don. Tbh it was more a setting I was looking for because I keep
accidentally overwriting the hidden rows. Thanks

"Don Guillett" wrote:


One way to copy a8 to visible in a9:a20

Sub CopyToVisibleCellsOnly()
For Each c In Range("a9:a20")
If c.Rows.Hidden = False Then Range("a8").Copy c
Next
End Sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Shazzer" wrote in message
...
When I use the fill handle to copy something down to a new row, the hidden
rows in between are also filled in. Is there any way I can stop this so
that
it only copies to the rows that are showing? Thank you.





All times are GMT +1. The time now is 12:14 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com