VBA: Creating function to find last row of the sheet.

Hello Experts.
Can somebody help me with the following query... This code will find last row of a sheet..but do not want to repeat for every sheet.

Dim lrow as long
Lrow=range ("a"& rows.count).end (xlup).row

Please help me to create function which can be used for any sheet..Thanking you in Advance.