property myOutputDirectory : "/Users/jomcmani/Desktop/Addresses" tell application "Address Book" set indexFile to my blankFile("index.html") my out("", indexFile) my out("Address Book", indexFile) my out("", indexFile) my out("

Address Book

", indexFile) my out("Click on a name below for address book information:
", indexFile) end tell on out(theText, theFile) write (theText as string) & return to theFile starting at eof end out on multiLineOut(theText, theFile) repeat with c from 1 to the number of paragraphs in theText my out((paragraph c of theText) & "
", theFile) end repeat end multiLineOut on blankFile(filename) set filePath to (myOutputDirectory & "/" & filename) as POSIX file open for access filePath with write permission set eof of filePath to 0 close access filePath return filePath as alias end blankFile