![]() |
macro that will paste a number in first blank cell of a column
I would like to create a formula or macro that will take a number that always
comes from the same cell but then pastes that information in the first blank cell within a column. |
macro that will paste a number in first blank cell of a column
Select the cell you want to copy and run this macro:
Sub PlaceIt() Set r = Selection v = r.Value For Each cell In Range("F:F") If cell.Value = "" Then cell.Value = v Exit Sub End If Next End Sub The code uses column F, but you can change it. If you click on a cell, say B9, and run the macro, then value in B9 will be pasted to the first cell in column F that is blank. -- Gary''s Student - gsnu200909 "asebes" wrote: I would like to create a formula or macro that will take a number that always comes from the same cell but then pastes that information in the first blank cell within a column. |
All times are GMT +1. The time now is 07:58 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com