I'm trying to set a range using the following code:
Set rng1 = Range(Cells(6, TotalAmount), Cells(330, TotalAmount).End(xlUp))
It didn't work. It selected the range $P$4:$P$6 while p7 to p16 are not empty. What I want is a range starting from p6 down to before the first empty cell.
I tried the following code, it did not work either.
Set rng1 = Range(Cells(6, TotalAmount), [Cells(330, TotalAmount)].End(xlUp))
neither did this code:
Set rng1 = Range(Cells(6, TotalAmount), [Cells(330, TotalAmount).address].End(xlUp))
Any suggestion?
Set rng1 = Range(Cells(6, TotalAmount), Cells(330, TotalAmount).End(xlUp))
It didn't work. It selected the range $P$4:$P$6 while p7 to p16 are not empty. What I want is a range starting from p6 down to before the first empty cell.
I tried the following code, it did not work either.
Set rng1 = Range(Cells(6, TotalAmount), [Cells(330, TotalAmount)].End(xlUp))
neither did this code:
Set rng1 = Range(Cells(6, TotalAmount), [Cells(330, TotalAmount).address].End(xlUp))
Any suggestion?