View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ian[_17_] Ian[_17_] is offline
external usenet poster
 
Posts: 11
Default setting search range from VBA

I have the following to find the last cell used


myrow = range("sheet1!S65536").END(xlup).row + 1



I then need to search in cells based on the last cell found




or each cell in range(z3:zx") 'x = myrow above

if len(trim(cell.value)) < 1 then count = count + 1

next cell

range("a1").value = count


How can i pass the myrow value so i can make it my range for search
from z3 to z(myrow) ?

thanks,