ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Controls, pages and windows / User Groupware functions
  • Properties specific to gpwUser variables
  • Functions that use the gpwUser type:
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
The gpwUser type is used to describe and modify the characteristics of a user of WEBDEV or WINDEV User Groupware.
Note: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable.
Example
WEBDEV - Server code
// Valeurs du nouvel utilisateur
clUtilisateur is gpwUser
clUtilisateur.Email = SAI_Email
clUtilisateur.Login = SAI_Login
clUtilisateur.Password = SAI_MotPasse
clUtilisateur.LastName = SAI_Nom
clUtilisateur.FirstName = SAI_Prenom
clUtilisateur.PhoneNumber = SAI_Telephone

// Ajout de l'utilisateur
IF gpwAddUser(clUtilisateur) = False THEN
	Info("Impossible d'ajouter l'utilisateur.")
	RETURN
END
// Activation de l'utilisateur
SWITCH gpwActivateUser(clUtilisateur.Login)
	// Pour une activation par email
	CASE gpwActivationByEmail
		PopupDisplay(POPUP_ValidationInscription)
	// Pour une activation immédiate
	CASE gpwActivationImmediate
		// Connecte directement l'utilisateur
		gpwConnectUser(clUtilisateur.Login, clUtilisateur.Password)
		// Affiche la popup de confirmation
		PopupDisplay(POPUP_ConfirmationInscription)
	OTHER CASE
		Info("Impossible d'activer l'utilisateur.")
END
Properties

Properties specific to gpwUser variables

The following properties can be used to define the characteristics of gpwUser variables:
NameType usedEffect
AccessRightsInteger constantUser access rights:
  • gpwRightAddApplication: Right to add an application to the Private Store.
  • gpwDroitAucun: No addition rights.
EmailCharacter stringUser's email address.
EnabledBoolean
  • True if user is enabled,
  • False otherwise.
FirstNameCharacter stringUser's first name.
IDExternalCharacter stringIdentifier of the user in a database external to the groupware. This property can be used for example to link the user of the User Groupware of the User file of the application that uses the groupware by referencing its identifier.
LoginCharacter stringUsername.
NameCharacter stringUser's last name.
PasswordCharacter string or Secret stringUser password.
This password is not retuned when gpwGetUserInfo is used to get the user information.
New in version 2025
Secret strings: If you use the secret string vault, the type of secret string used for this parameter must be "ANSI or Unicode string".
To learn more about secret strings and how to use the vault, see Secret string vault.
New in version 2025
Android Secret strings are not available for this parameter in Android/Android widget applications.
PasswordToEnterBoolean
  • True if users must enter their password the first time they log in,
  • False otherwise.
PhoneCharacter stringUser's phone number.
SupervisorBoolean
  • True if the user is a supervisor,
  • False otherwise.
TOTPKeyCharacter stringTOTP key linked to the user for the two-factor authentication.
Note: This property is only taken into account for User Groupware in WDBaaS mode and the Private Store.
TrustListBufferIf the two-factor authentication is turned on, the user can indicate that the current computer is a trusted computer. This property lists all user-defined trusted devices, computers and browsers.
Note: In the user profile interface provided by User Groupware, you can delete trusted machines.
TwoFactorAuthenticationIntegerTwo-factor authentication management mode:
  • 0: Inactive two-factor authentication. Two-factor authentication is turned off for the user and is not required.
  • 1: Active two-factor authentication. Two-factor authentication is turned on for the user.
  • 2: Activate two-factor authentication. Two-factor authentication is required but it is turned off.
Note: This property is only taken into account for User Groupware in WDBaaS mode and the Private Store.
Remarks

Functions that use the gpwUser type:

gpwAddUserAdds a user to the User Groupware database.
gpwFindUserRetrieves the characteristics of a user of the User Groupware.
gpwGetUserInfoRetrieves information about the current user (application that uses the User Groupware).
gpwModifyUserModifies a user in the User Groupware database.
Minimum version required
  • Version 19
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/16/2025

Send a report | Local help