ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Communication / Contact functions (Lotus Notes or Android/iPhone/iPad)
  • Adding contacts into a Lotus Notes session
  • Adding contacts into the list of contacts found on the Andoid device
ContactAdd (Example)
Adding contacts into a Lotus Notes session
Adding contacts into the list of contacts found on the Andoid device
AndroidAndroid Widget This example is used to add a contact into the list of contacts found on the Android device. The information regarding the contact is entered in the WIN_NewContact window. The following code corresponds to the validation of this window.
// Local variables
tContact is Contact
tPhone is Phone
tEmail is EmailAddress
 
// Identity
tContact.Name = EDT_LastName
tContact.FirstName = EDT_FirstName
 
// Phone numbers
// Fixed
IF EDT_HomePhone <> "" THEN
tPhone.PhoneNumber = EDT_HomePhone
tPhone.Type = phoneHome
Add(tContact.Phone, tPhone)
END
 
// Cell
IF EDT_CellPhone <> "" THEN
tPhone.Number = EDT_CellPhone
tPhone.Type = phoneCellHome
Add(tContact.Phone, tPhone)
END
 
// Email
IF EDT_Email <> "" THEN
tEmail.Address = EDT_Email
tEmail.Type = emailHome
Add(tContact.Email, tEmail)
END
 
// Add
IF NOT ContactAdd(tContact, gSource) THEN
Error("Unable to create the contact")
ELSE
WIN_TableContacts.RefreshContactList()
Close()
END
Minimum version required
  • Version 11
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help