View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.programming
sali[_2_] sali[_2_] is offline
external usenet poster
 
Posts: 24
Default "Move to bottom of range"

"Per Jessen" wrote in message
...
ActiveCell.SpecialCells(xlLastCell).Offset(1,0).Se lect

Or like this:

Range("A1").End(xlDown).Offset(1,0).Select

Regards,
Per

On 18 Apr., 10:23, Copacetic
wrote:
Hello,

I have some code that adds the contents of one sheet to the end of
another. How do I correctly select the first empty cell below the first
sheet that I want to add data to?



sheet that has to have data [rows] added usualy need to have some known
column structure, otherwise it is mismatched, wrong, invalid

i use framework something like this:

----
row=1
bad=0
lastrow=0
do while bad<100 'max number of bads in sequence
if not valid_row(row) then 'function to test row validity/emptyness
bad=bad+1
else
bad=0
lastrow=row
end if
row=row+1
loop
-----

does such a test make sense, or is just time & cpu vasting?