I have a very specific issue and I'm trying to work it out to little success. I have 2 sheets in my file and I need to be able to sort rows on one based on the column in the other.
Example:
Sheet 1:
Date - Invoice# - Amount
Date - Invoice# - Amount
Date - Invoice# - Amount
Date - Invoice# - Amount
Date - Invoice# - Amount
Sheet 2:
Invoice# - Invoice# - Invoice#
Merch ---- Merch ---- Merch
Freight -- Freight -- Freight
So sheet 1 is able to be sorted by invoice simply enough with the built-in Sort Ascending. And sheet 2 was simple enough by clicking data -> sort -> Row 1 (options -> left to right). However, the invoice numbers have recently turned over and gone back from 999999 to 000001 so that sorting option is now out. Sheet 1 can still be sorted, now by date instead but there is no such option for sheet 2.
My theory is I can use the order of the invoices on sheet 1 after sorting by date to determine the sort order on sheet 2. That, or somehow convince Excel that 000001 > 999999 when sorting.
I'm OK with macros and VBA but I'm not sure where to start here. Any help would be greatly appreciated!
Example:
Sheet 1:
Date - Invoice# - Amount
Date - Invoice# - Amount
Date - Invoice# - Amount
Date - Invoice# - Amount
Date - Invoice# - Amount
Sheet 2:
Invoice# - Invoice# - Invoice#
Merch ---- Merch ---- Merch
Freight -- Freight -- Freight
So sheet 1 is able to be sorted by invoice simply enough with the built-in Sort Ascending. And sheet 2 was simple enough by clicking data -> sort -> Row 1 (options -> left to right). However, the invoice numbers have recently turned over and gone back from 999999 to 000001 so that sorting option is now out. Sheet 1 can still be sorted, now by date instead but there is no such option for sheet 2.
My theory is I can use the order of the invoices on sheet 1 after sorting by date to determine the sort order on sheet 2. That, or somehow convince Excel that 000001 > 999999 when sorting.
I'm OK with macros and VBA but I'm not sure where to start here. Any help would be greatly appreciated!