ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Do until cell is empty (https://www.excelbanter.com/excel-discussion-misc-queries/41558-do-until-cell-empty.html)

Hru48

Do until cell is empty
 

Hey,

I have a macro that at the end of each irrteration deletes a cell from
colum A. How do i tell it to run until it runs of of values in column
A? Column A is empty

Cheers


--
Hru48
------------------------------------------------------------------------
Hru48's Profile: http://www.excelforum.com/member.php...o&userid=24895
View this thread: http://www.excelforum.com/showthread...hreadid=397701


FSt1

hi.
dim c as range 'current
dim n as range 'next
set c = range("A1")
do while not isempty(c)
set n = c.offset(1,0)
your code here
set c=n
loop

regards
FSt1
"Hru48" wrote:


Hey,

I have a macro that at the end of each irrteration deletes a cell from
colum A. How do i tell it to run until it runs of of values in column
A? Column A is empty

Cheers


--
Hru48
------------------------------------------------------------------------
Hru48's Profile: http://www.excelforum.com/member.php...o&userid=24895
View this thread: http://www.excelforum.com/showthread...hreadid=397701



Hru48


Thanks alot :)


--
Hru48
------------------------------------------------------------------------
Hru48's Profile: http://www.excelforum.com/member.php...o&userid=24895
View this thread: http://www.excelforum.com/showthread...hreadid=397701



All times are GMT +1. The time now is 04:01 AM.

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