Delete multiple categories?

P

philberesford

After finally getting my Entourage address book, OSX address book and
my P800 phone address book 'synched up' I have ended up somehow with
over 800 categories 790+ of which are 'blank' oe 'empty'. It seems
that the only way i can delete them is if I go to 'edit categories'
and manually delete one by one. This is going to take weeks!!! :(

Is there another way I can delete multiple categories?
all help greatly appreciated.

Phil
 
B

Barry Wainwright

After finally getting my Entourage address book, OSX address book and
my P800 phone address book 'synched up' I have ended up somehow with
over 800 categories 790+ of which are 'blank' oe 'empty'. It seems
that the only way i can delete them is if I go to 'edit categories'
and manually delete one by one. This is going to take weeks!!! :(

Is there another way I can delete multiple categories?
all help greatly appreciated.

Phil

Well, I'd do it with a script. But, without knowing how your blank entries
are labelled internally I can't write the script for you.

So, try this:

Fire up Script Editor, and in a new script window type this:

tell application "Microsoft Entourage" to get name of every category

(That's all on one line)
At the bottom of the window click on the 'results' tab, then click the 'run'
button. You should get a result that looks like this:

{"Junk", "Birthdays", "Business", "Church", "Customers", "Email
Correspondents", "F1", "Family", "Friends", "Friends/Family", "Holiday", ...
Etc

Your 'blank' entries may show up with a name of "", or maybe 'missing value'
(without the quotes) or maybe even "Blank". Whatever, with so many of them,
they should be easy to spot.

Now, copy this script into the editor window:

tell application "Microsoft Entourage"
repeat with x from (count every category) to 1 by -1
if name of category x is "" then delete category x
end repeat
end tell

Change the 3rd line so that the "" matches whatever the blank category name
was in the results of the first script you ran.

Run the script.

Bingo - the blank categories should be gone :)
 
Top