mike m said:
i have a list of 8000 e-mail addresses and i need to remove 700 of them that
contain a certain address (ex: @yourcompany.com). Does anyone know how to
create a formula that would look for them, then remove them from their
original cell and move them to a different cell???
Thansk!
I would do this "manually" rather than with VBA. Basically it would involve
sorting your entire data table by the address (the portion after the @). Then
simply cut/paste those containing your target (eg @yourcompany.com).
To sort by address you need to extract just the address into a new column.
It's easiest to describe in three steps (each a new column). Here are the
formulas, assuming the full email is in column A:
=FIND("@",A4) =LEN(A4) =RIGHT(A4,E4-D4)
When you've done that you will see just the portion after the @ sign in the
last column. Sort the entire datatable by that column, find your group, and
cut/paste. Delete the newly blank rows and you're there.
If you need to restore the original sort order, create a new column before
you start, and fill it with sequential numbers. Then you can sort on that
when you're done with the cut/paste. Be sure to make this column part of your
data table when you sort by address!
Art