groups

info


tags: applescript,address,book

Link to this snippet:


Download to Code Collector

language: AppleScript
licence: Other

Delete Nameless Entries - Address Book

options: send to code collectorview all seydoggy's snippets
(*
Delete Nameless Entries

By Adam Merrifield <http://seydoggy.com>

This script will cause irreversible changes to contacts in your Address Book.

USE AT YOUR OWN RISK!!

This script finds, then deletes any entry in your Address Book that has no first or last name

- r1 12-23-09 12:22
*)
tell application "Address Book"
	activate
	set thePeople to every person whose first name is missing value and last name is missing value
	repeat with i from 1 to count of thePeople
		set thePerson to (item i of thePeople)
		delete thePerson
		save
	end repeat
end tell