PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Possible error cases:
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
GglListContact (Function)
In French: GglListeContact
Retrieves the list of contacts associated with the specified Google account.
Caution: the access to the Google Contacts changes from November 17, 2014
From November 17 2014, Google is only using the Google API version 3 (Google API version 2 is abandoned). This change of version has modified the exchange format of data used by the functions for accessing the Google Contacts.
An "OAuth 2.0" authentication is now required to access this service. This authentication mode requires:
  • the declaration of the application in the Google console. To use the Google Contacts, the application must use the "Contacts API" service.
  • the use of new properties in the gglConnection variable.
See the help about GglConnect for more details.
Caution: The gglCalendar, gglEvent and gglLocation variables are also modified. Some properties become obsolete with the Google API version 3: they must not be specified anymore.
Example
// Connection
Cnt is gglConnection
...
// Retrieves all the contacts
arrContacts is array of 0 gglContact = GglListContact(Cnt)

// Example with 10 contacts per page:
// First page
// Retrieves all the contacts, with a maximum of 10 contacts, starting from index 1
arrContacts = GglListContact(Cnt, "", 1, 10)
// Second page
// Retrieves all the contacts, with a maximum of 10 contacts, starting from index 11
arrContacts = GglListContact(Cnt, "", 11, 10)
// Browse the contacts
MyContact is dynamic gglContact
FOR EACH MyContact OF arrContacts
Trace(MyContact..Name)
END
Syntax
<Result> = GglListContact(<Google Connection> [, <Group of Contacts> [, <First Element> [, <Maximum Number of Contacts>]]])
<Result>: Array of gglContact variables
Name of array of gglContact variables.
<Google Connection>: gglConnection variable
Name of the gglConnection variable to use. This connection was validated by GglConnect.
Versions 20 and later
Caution: the properties of the gglConnection variable must be revised for the OAuth 2.0 authentication.
New in version 20
Caution: the properties of the gglConnection variable must be revised for the OAuth 2.0 authentication.
Caution: the properties of the gglConnection variable must be revised for the OAuth 2.0 authentication.
<Group of Contacts>: Optional Unicode character string
Name or identifier of the group of contacts to list. If this parameter corresponds to an empty string (""), all the groups are listed. This parameter corresponds to an empty string by default.
<First Element>: Optional integer
Number of the first contact to retrieve (1 by default). This parameter must be greater than or equal to 1.
<Maximum Number of Contacts>: Optional integer
Maximum number of contacts to retrieve (0 by default). If this parameter corresponds to 0, the maximum number of contacts is unlimited. This parameter must be greater than or equal to 0.
Remarks

Possible error cases:

  • The Internet connection is not valid.
  • The authentication was not performed properly.
  • The XML response of the server cannot be read.
To find out whether an error occurred, use the ErrorOccurred variable.
Components
WINDEVWEBDEV - Server codeReports and Queries wd230ggl.dll
Windows Mobile wp230ggl.dll
Minimum required version
  • Version 14
This page is also available for…
Comments
Click [Add] to post a comment