Hi Everyone
I have an excel table with line items from an order (each row represents a reference to an SKU). The purpose of this spreadsheet is to create an import document for XERO. Now XERO does not have an import field for Freight so the only way to do is to:
1. Cycle through the table looking for the last refernce to an order number
2. Insert a row below the last reference and insert a row
3. Copy data into that newly created row
An example
In the screen shot attached, the code would cycle through the table to find the last instance of InvoiceNumber N1082272, then insert a row below, make a copy of the data from the last instance row of the order number and change the InventoryItemCode to "Freight" and the Description to "Freight Cost". It would then continue down the table finding the last instance of order N1082328, rinse and repeat as per above.
Running this with VBA will save a lot of time as we currently have to insert the row, copy the data, change the SKU and Description manually.
Any help would be greatly appreciated.
I have an excel table with line items from an order (each row represents a reference to an SKU). The purpose of this spreadsheet is to create an import document for XERO. Now XERO does not have an import field for Freight so the only way to do is to:
1. Cycle through the table looking for the last refernce to an order number
2. Insert a row below the last reference and insert a row
3. Copy data into that newly created row
An example
In the screen shot attached, the code would cycle through the table to find the last instance of InvoiceNumber N1082272, then insert a row below, make a copy of the data from the last instance row of the order number and change the InventoryItemCode to "Freight" and the Description to "Freight Cost". It would then continue down the table finding the last instance of order N1082328, rinse and repeat as per above.
Running this with VBA will save a lot of time as we currently have to insert the row, copy the data, change the SKU and Description manually.
Any help would be greatly appreciated.