Thanks very much for taking the time to read this. Fist of all I need to clarify that I am not a developer (not even close) or anything really closely related to IT/Programming, so I'm guessing my efforts will be kind of funny to some of you (if not all), however I still need your help so please bear with me while I try to explain my situation.
What I have is an Excel worksheet, with the vast majority of its data arranged on column A. This data is an array of names with their addresses right underneath and their telephone numbers two cells below that address. Then after a few rows follows the next name etc... Some of these phone numbers are landlines (numbers < 3,000,000) and some are mobiles (numbers > 3,000,000). When a person has more than one number then his/her name repeats itself a few rows underneath the person's first number followed by the address right underneath that and then the extra number on the column on the right (column B, same row with address).
What I would like is to have: the name in column A, its address in column B (same row as A), its phone in column C if it's a landline (same row as A)/ in column D if it's a mobile (same row as A).
And so What I'm trying to do is:
1) Select the first cell (A1)
2) Check if the contents are text
3) If it is, move the address to the correct cell
4) Check if the cell next to where the address WAS is empty
5) If it has a number and it is: a landline move it to the correct cell/ a mobile to the correct cell
6) If it's empty, move the landline number to the correct cell/ a mobile number to the correct cell
7) Select the cell underneath the one where the phone WAS
8) lf the cell (A1) does not contain text, select the one underneath and loop the steps from #2 for 40,000 cells
However I can't get it to work. So please help. I've attached an excel file with some sample names and numbers as well as the Macro named "Main". Thank you very very much...