If you're looking to do it with vba you can use something like the following:
This will also find the last used row no matter what column it's found in.
I just want to point out a couple of things about the above code line. First, since you are searching using xlPrevious, and since you want the "last" row, you can leave out the After argument as the search starts from the top-left cell of the specified range by default (A1 in this case because all cells are specified). So this will do the same as what you posted...
Code:
However, a point needs to be made about your missing LookIn argument. Because the Find method "remembers" the setting for the last time Find was used on the system, you have no way of knowing if it is set to xlValues or xlFormulas and each of these could produce different results depending on what is on the worksheet. xlValues will find the last displayed piece of data no matter if that data is a constant value or the non-empty result of a formula. On the other hand, xlFormulas will find the last filled-in cell even if that cell is a formula displaying the empty string (""). So, to summarize, using LookIn:=xlValues will ignore formulas displaying the empty string meaning if you use LstRw to establish a row after which to begin copying data/formulas to, you could end up overwriting existing formulas (if they are displaying the empty string) whereas using LookIn:=xlFormulas will locate the actual last used row even if it "looks" like nothing is there (because of a formula displaying the empty string). So, depending on what is needed, I think PatPat should use one of these...
' Find last row displaying visible data
' Find last row with anything in it (including formulas displaying the empty string ("")
Bookmarks