Removing redundant addresses?

M

Mama Bear

I'm using Word 2000 SR-1 and was wondering if there's a way to clean up
redundant address entries in a mailing list that accidentally got combined
with another that was partially the same?
 
C

Carol

If you're referring to an Outlook distribution list, simply open
Outlook and click on Contacts and search for the distribution list.
Double click on it and then delete the redundant names.

If this isn't helpful to you, please post back here.
 
M

Mama Bear

Carol said:
If you're referring to an Outlook distribution list, simply open
Outlook and click on Contacts and search for the distribution list.
Double click on it and then delete the redundant names.

If this isn't helpful to you, please post back here.

No, I was referring to MS Word, that was why I posted it here. I wouldn't
touch Outlook.
 
Z

Zilbandy

I'm using Word 2000 SR-1 and was wondering if there's a way to clean up
redundant address entries in a mailing list that accidentally got combined
with another that was partially the same?

Sort the list alphabetically by name, or address and starting looking
for identical entries. This doesn't become a serious inconvenience
until you get several hundred names or more on the list. I know, I've
done it with a list of 1100 names. :/ Just think, if you had started
this when you first posted, you'd be done now. :)
 
M

Mama Bear

Zilbandy said:
Sort the list alphabetically by name, or address and starting looking
for identical entries.

It's not just names, that's the problem. It's a name on one line, address
on the next, city and state on the next, then zip code on the next and
phone on the next. I could make a real scrambled up mess of it by sorting?
 
W

wisccal

I would do it as follows:

First copy the data from Word into Excel. Then run the following macro:

Sub main()
Dim wb As Excel.Workbook, wsFrom As Excel.Worksheet, wsTo As
Excel.Worksheet, rngFrom As Excel.Range, rngTo As Excel.Range
Dim NO_OF_RECORDS As Integer

Set wb = ThisWorkbook
Set wsFrom = wb.Sheets("Sheet1") 'This contains the addresses
Set wsTo = wb.Sheets("Sheet2") 'That's where the data is going to be
copied to
Set rngFrom = wsFrom.Range("A1")
Set rngTo = wsTo.Range("A1")
NO_OF_RECORDS = 1000 'adjust as necessary

transpose rngFrom, rngTo, NO_OF_RECORDS, 1, 0

Set wsFrom = wb.Sheets("Sheet2")
Set wsTo = wb.Sheets("Sheet3")
Set rngFrom = wsFrom.Range("A1")
Set rngTo = wsTo.Range("A1")

'transpose rngFrom, rngTo, NO_OF_RECORDS, 0, 1

Set wb = Nothing
Set wsFrom = Nothing
Set wsTo = Nothing
Set rngFrom = Nothing
Set rngTo = Nothing
End Sub

Sub transpose(ByVal rngFrom As Range, ByVal rngTo As Range, ByVal
NO_OF_RECORDS As Integer, ByVal r As Integer, ByVal c As Integer)
Dim colFrom As Integer, rowFrom As Integer, colTo As Integer, rowTo As
Integer
Dim i As Integer, tmp As String

colFrom = 1
rowFrom = 1
colTo = 1
rowTo = 1

For i = 1 To NO_OF_RECORDS
While (rngFrom.Value <> "")
rngTo.Value = rngFrom.Value
Set rngFrom = rngFrom.offset(r, c)
Set rngTo = rngTo.offset(c, r)
Wend
Set rngFrom = rngFrom.offset(1, -(rngFrom.Column - 1))
Set rngTo = rngTo.offset(1, -(rngTo.Column - 1))
Next i
End Sub

This transposes rows in Sheet1 to columns in Sheet2. Sort them, delete
duplicates, and rerun macro with the first call to transpose commented
out and the second one uncommented.

Let me know if this helps.

Regards,
Steve
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top