HowTo: Using AddContact From Contacts for Smart Devices

Official Content
This documentation is valid for:

This tutorial will guide you through a simple example on how to use this API.

AddressBook has three methods that may be invoked from a SD.

  • AddContact
  • ViewContact
  • RemoveContact

In this article we will to see how the AddContact method works.

Availability

For the time being the methods ViewContact and RemoveContact are not supported in Android.

Syntax

AddContact()

This method expects the following parameters (see the Note below):

primera

Let's create the following Transactions for our example:

Persona

COmpany

Apply the WWSD pattern to our transactions (see Applying Work With for Smart Devices Pattern).

Creating our action

In the pattern screen select the Section node.

Take a look at the screen on your right, wich has some default actions. To add a new Action press the Add button.

WWSDACtion

After the Action has been created, add the code for the associated event.

PropiedadAction

Note: The First Name and Last Name parameters are mandatory. Email, Phone, Company Name, Photo and Message are optional. Even when some parameters are not included, they should be part of the call code. Also, because parameters are sent by position, when you want to skip one parameter you will have to add it with empty string value.

Drag the new Action to the Action Bar.

actionbar

Examples of each plataform

Android

android1

Android2

Blackberry

AddContact BB1

AddContact BB2

AddContact BB3

iOS

IPAD ADDCONTACT

IPAD ADDCONTACT2

IPA ADDCONTACT3

Videos

Start Video Events in Mobile Applications