0

I am currently trying to combine two sheets of data which are updated periodically and then remove duplicates.

I have 4 worksheets:

  • Sheet X
  • Sheet Y
  • Sheet Z
  • Sheet AA

Sheet X and Y are updated hourly and only ever grow.

I wish to clear Sheet Z completely, clear columns C:P on Sheet AA, Then copy all the data from X and Y and paste into Z, sort by column A, oldest to newest, then remove duplicates from columns B & E. Then copy all the data left and paste into Sheet AA where I run further calculations and VLOOKUPS from.

The issue I have is at the moment I am only copying/editing data up to the row which is recorded in the macro. Is there a way in which to select up to the last populated Row?

L42
  • 19,427
  • 11
  • 44
  • 68
Mr M
  • 13
  • 2
  • Possible duplicate of [Error in finding last used cell in VBA](https://stackoverflow.com/questions/11169445/error-in-finding-last-used-cell-in-vba) – Victor K Dec 26 '17 at 22:21
  • 1
    Possible duplicate of [How can I find last row that contains data in the Excel sheet with a macro?](https://stackoverflow.com/questions/71180/how-can-i-find-last-row-that-contains-data-in-the-excel-sheet-with-a-macro) – Maki Dec 27 '17 at 00:49
  • Welcome to Stack Overflow! Please take a few minutes to check out the [tour] as well as [ask] and [mcve]. You can [edit] your question to provide more specific information about your issue, starting with some examples showing what you have and what you need to do. – ashleedawg Dec 27 '17 at 02:50

0 Answers0