Login/Logout API Support

Several APIs exist that give programmed applications some control over the CIMPLICITY login/logout activities.  Versions exist in both C callable and basicscript callable forms.

C callable routines

The C callable routines located in rcm.dll are:

COR_I4 GEFCIMPLICITY_setuserpw (TCHAR *proj, TCHAR *CIMPuser, TCHAR *pw)

COR_I4 GEFCIMPLICITY_remuserpw (TCHAR *proj, TCHAR *CIMPuser, TCHAR *pw)

COR_I4 GEFCIMPLICITY_login(TCHAR *proj)

COR_I4 GEFCIMPLICITY_logout(TCHAR *proj)

Be aware that:

  • These functions are defined in the header file <inc_path\cor_user_api.h>
  • To use these API's link with rcm.lib.
  • The return value can be one of the following.
  • COR_SUCCESS
  • COR_WARNING
  • COR_FAILURE

Corresponding basic script extensions

CimSetProjectUserPassword(CIMPuser as string, pw as string, proj as string)

CimClearProjectUserPassword(CIMPuser as string, pw as string, proj as string

CimLogin (proj as string)

CimLogout (proj as string)

General Guidelines

The following routines can be called to avoid the CIMPLICITY invoked GUI.

Purpose To enable an application to have logins reference the set data
Routines GEFCIMPLICITY_setuserpw() or CimSetProjectUserPassword()
Description Use the  routine to set the CIMPLICITY user and corresponding password (if there is one) for the project from which resources are about to be requested, Do this before you request any CIMPLICITY resources.
  • When the application requests a CIMPLICITY resource requiring a login, these set parameters will be used to provide the login action with data.
  • These parameters remain set until cleared by an application.
  • Therefore, if the system timeouts should cause a logout, a subsequent request would again reference this data for login.
A logout can happen after all requests for resources have been removed.
Note: If the provided data is not valid, no attempt is made to obtain the login information via GUI or otherwise, and no error is given. These routines can be called multiple times to change the data that should be referenced on future login attempts without having to clear any data already set.
Purpose To enable an application to stop having logins reference the set data
Routines GEFCIMPLICITY_remuserpw() or CimClearProjectUserPassword()
Description The routine:
  • Does not force a logout of any currently logged in user
  • Does disable the automatic attempt to login.
Purpose To force a logout of the currently logged in user
Routine CimLogout
Description After CimLogout is called, either CimLogin must be called or the similar action initiated from the Login Panel, before data can be retrieved again.
Purpose To cause CIMPLICITY to initiate a login sequence
Routine CimLogin
Description This most likely will be preceded by a call to CimSetProjectUserPassword and CimLogout, to force a change in the currently logged in CIMPLICITY user.