M-Files API 22.6.11519.0
LogInAsUser Method
MFilesClientApplication Object : LogInAsUser Method
User name as a string. Not used with the MFAuthTypeLoggedOnWindowsUser authentication mode.
Password as a string. Not used with the MFAuthTypeLoggedOnWindowsUser authentication mode.
Domain for the user. Used only with the MFAuthTypeSpecificWindowsUser authentication mode.
The Service Principal Name as a string.
Description
Logs in to the vault with the specified name (e.g., 'Sample Vault') using the specified credentials.
Syntax
Visual Basic
Public Function LogInAsUser( _
   ByVal VaultConnection As String, _
   ByVal AuthType As MFAuthType, _
   ByVal UserName As String, _
   ByVal Password As String, _
   Optional ByVal Domain As Variant, _
   Optional ByVal SPN As Variant _
) As Vault
Parameters
VaultConnection
AuthType
ValueDescription
MFAuthTypeLoggedOnWindowsUserWindows authentication with current user credentials.
MFAuthTypeSpecificMFilesUserM-Files authentication, user needs to specify the credentials.
MFAuthTypeSpecificWindowsUserWindows authentication, user needs to specify the credentials.
MFAuthTypeUnknownUnspecified authentication method.
UserName
User name as a string. Not used with the MFAuthTypeLoggedOnWindowsUser authentication mode.
Password
Password as a string. Not used with the MFAuthTypeLoggedOnWindowsUser authentication mode.
Domain
Domain for the user. Used only with the MFAuthTypeSpecificWindowsUser authentication mode.
SPN
The Service Principal Name as a string.
See Also

MFilesClientApplication Object  | MFilesClientApplication Members