AddressBookContact.LastName
From Xojo Documentation
This item was deprecated in version 2019r2. |
Property (As AddressBookData )
This property is only available on the macOS platform. For cross-platform compatibility, use #If...#Endif with the Target... specifiers to make sure you will not attempt to use this property on an incompatible platform. |
aAddressBookContact.LastName = newAddressBookDataValue
or
AddressBookDataValue = aAddressBookContact.LastName
Supported for all project types and targets.
or
AddressBookDataValue = aAddressBookContact.LastName
Supported for all project types and targets.
Last Name entry.
Sample Code
The following code adds the LastName field to a new contact.
Dim book As New AddressBook
Dim myContact As AddressBookContact
book = System.AddressBook
myContact = New AddressBookContact
myContact.FirstName = "Xena"
myContact.LastName = "Smith"
book.Add(myContact)
If book.HasUnsavedChanges Then
If book.Save Then
MsgBox("The AddressBook was saved!")
End If
Else
MsgBox("There were no unsaved changes!")
End If
Dim myContact As AddressBookContact
book = System.AddressBook
myContact = New AddressBookContact
myContact.FirstName = "Xena"
myContact.LastName = "Smith"
book.Add(myContact)
If book.HasUnsavedChanges Then
If book.Save Then
MsgBox("The AddressBook was saved!")
End If
Else
MsgBox("There were no unsaved changes!")
End If