示例:
结果如下:"Sandu_D._Serban"
对于我的Mac地址簿中的所有联系人。
由于
答案 0 :(得分:0)
使用applescript你可以这样做(使用脚本编辑器运行):
tell application "Address Book"
set allNames to ""
set peopleCount to (count every person)
repeat with i from 1 to peopleCount
set firstName to (get first name of person i)
set middleName to (get middle name of person i)
set lastName to (get last name of person i)
set oneName to ""
if firstName is not missing value then
set oneName to oneName & firstName
end if
if middleName is not missing value then
set initial to first character of middleName
set oneName to oneName & "_" & initial & "."
end if
if lastName is not missing value then
set oneName to oneName & "_" & lastName & "
"
end if
if firstName is missing value or lastName is missing value then
set oneName to ""
end if
set allNames to allNames & oneName
end repeat
set the clipboard to allNames
end tell
此脚本将名称列表复制到剪贴板。下次粘贴时,您将获得名称列表(如果您的地址簿中有很多名称,请稍等一下。)
BR,
的Juha