How can my macro go to the last active cell without using Range:


Posted by giohess on January 28, 2001 3:26 PM

At work I import large text files into excel and reformat the information. I wrote a macro to perform all my formatting. The text files vary in size so in my macro I indicate the Range of active cells, but I have to do this everytime I format a file. Is there a way that my macro will go to the last active cell without haveing to give it a range?



Posted by keekee on January 30, 2001 11:21 AM

Range("A1").Select
ActiveCell.SpecialCells(xlLastCell).Select

this will go to a1 and then go to the last cell in your data range. it will NOT select the range, just go to the last cell. If you need more, let me know.