ThrottleWorks
Excel Ninja
I am using a loop. I am taking a range from A1 to A5000.
I do not need the range till A5000 but since I am not able to define the last used cell value in the range I am taking A5000.
I am using following line to define the range
Set rng = range(“a1:a5000”)
I can get last used cell by using xlendup but I am not able to replace this value with A5000.
How can I replace A5000 with the last used cell in the column, can anyone please help me in this.
I do not need the range till A5000 but since I am not able to define the last used cell value in the range I am taking A5000.
I am using following line to define the range
Set rng = range(“a1:a5000”)
I can get last used cell by using xlendup but I am not able to replace this value with A5000.
How can I replace A5000 with the last used cell in the column, can anyone please help me in this.