PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
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
Checks the existence and validity of the password for a user of the user groupware.
Example
nRes is int = gpwCheckUser(Login, Password)
// If the login failed
IF nRes <> gpwOk THEN
       SWITCH nRes
               CASE gpwError: Error("Error while initializing the groupware.")
               CASE gpwUnknownUser: Error("Unknown user.")
               CASE gpwInvalidPassword: Error("Invalid password")
       END
       EndProgram()
END
Syntax
<Result> = gpwCheckUser(<Login> , <Password>)
<Result>: Integer
Result of the check:
gpwErrorAn error occurred. To find out the error details, use ErrorInfo.
gpwInvalidPasswordThe user password is not valid. It does not correspond to the user password described in the database of user groupware.
gpwOKThe user is connected.
gpwUnknownUserThe user is unknown: it is not found in the database of user groupware.
<Login>: Character string (with quotes)
Login of user.
<Password>: Character string (with quotes)
Password associated with the user login.
Components
WEBDEV - Server code wd230gpu.dll
Minimum required version
  • Version 19
Comments
GpwCheckUser Detail
//verifica login
nRes is int = gpwCheckUser(LOGINUSER, SENHACRIPT)

// If the login failed
IF nRes <> gpwOk and nRes <> 0

SWITCH nRes
//1
CASE gpwError: Error("Error while initializing the groupware.")
//2
CASE gpwUnknownUser: Error("Unknown user.")
//3
CASE gpwInvalidPassword: Error("Invalid password")
END

EndProgram() // erro

ELSE IF nRes = gpwOk and nRes = 0

Info("ok = gpwok")

END
BOLLER
Jan. 25 2017