Convert data file to AR system

Closed
Gravyrice - Sep 22, 2011 at 02:09 PM
rizvisa1 Posts 4478 Registration date Thursday January 28, 2010 Status Contributor Last seen May 5, 2022 - Sep 23, 2011 at 03:41 AM
Hello,

Gravyrice - Sep 22, 2011 7:05pm BST
Need help please. I am converting a Accounts receivable customers date file to our data format for our AR system. They have many columns of data from column A-P. Their customers account number is in column D. Here is the problem. They have multiple lines for each account number. They only write the address for the 1st account number. If the next line is the same account number then they don't move the customers name address into the fields they leave it blank until the account number is different. Our system requires the data to be in all fields. So if the account number in column D is 76883 and the next line contains the same account number 76883 then all the name and address fields are blank. So if the account number is the same then I need to copy the customer name (column F), customer addr1 (column G), addr2 (column H), addr3 (column I) into the next line for the entire data file. Here is the if statement defination. IF DI = DI+1 then copy FI to FI +1, GI to GI+1, HI TO HI +1. My problem is I don't know how to make it generic to copy each line and figure out a macro. Please help!
Related:

1 response

rizvisa1 Posts 4478 Registration date Thursday January 28, 2010 Status Contributor Last seen May 5, 2022 766
Sep 23, 2011 at 03:41 AM
Well you dont really need a macro, IMHO.
You can add a new column to the sheets. Have a formula that populate all the cells
then you copy and do paste special as values and delete the old column

Some thing like this for formula. Lets say your new column is Q
=IF(D2<> "", D2, Q1)
basic idea is that, on a given row, if there is a value in D, then have that value in Q else have the value of Q from the row above.
0