Hello everyone,
I am new to mapp UserX and I am trying to get a simple login working with MpUserXLogin. I have the problems below and would like help finding the cause.
Environment
- Automation Studio 4.12.10.39, target 4PPC50.0702-10A (Power Panel)
- Also tested in Automation Studio 6.7.0.187, target X20CP1685
Configuration
Config_1.mpuserxloginis linked togUserXLogin(declared asMpComIdentTypein Global.var)Config.mpuserxhas the component nameUserMgmtX, with the user Abin under UsersUser.usercontains the users Abin, Admin and anonym, with roles inRole.role- Password length is set to 5 in the UserX settings
- File device
USER, file extensionusr
Code (Main.st)
PROGRAM _INIT
UISetup.FileDevice := 'USER';
UISetup.FileExtension := 'usr';
UISetup.UserListSize := 20;
UISetup.RoleListSize := 9;
UISetup.ScrollWindow := 1;
END_PROGRAM
PROGRAM _CYCLIC
UserMgr.Enable := TRUE;
UserMgr.ErrorReset := ResetButton;
UserMgr.UISetup := UISetup;
UserMgr.UIConnect := ADR(UIConnect);
UserMgr();
UserLogin.MpLink := ADR(gUserXLogin);
UserLogin.Enable := TRUE;
UserLogin.ErrorReset := ResetButton;
UserLogin.UserName := ADR(sUserName);
UserLogin.Password := ADR(sPassword);
UserLogin.Login := LoginButton;
UserLogin.Logout := LogoutButton;
UserLogin();
END_PROGRAM
Problems
- AS 4.12:
UserLogingivesmpUSERX_ERR_USER_NOT_EXISTING, even though the user exists inUser.user. I write the name in the Watch window as a string ('Abin') and then setLoginButton. - AS 4.12:
UserMgr(MpUserXMgrUI) first showedmpUSERX_ERR_MPLINK_NULL, because I had not setUserMgr.MpLink. When I declareUserMgmtX : MpComIdentType;in Global.var and useUserMgr.MpLink := ADR(UserMgmtX);, I get an error that the MpLink is corrupted. [Add the exact error text and where it appears: build output or Watch window.] - AS 6: The same project now gives
mpUSERX_ERR_INVALID_CRED...onUserLogin. The password in my Watch window is'Admin123'. I am not sure whether it matches the password set for the user.
My questions
- How should the link variable of
Config.mpuserxbe declared and mapped forMpUserXMgrUIin AS 4.12? Is the name of the component enough, or do I need a mapping entry? - Do I need both
User.userand the Users list inConfig.mpuserxfor a local user system, with the same user name in both? - Does
MpUserXLoginneedMpUserXMgrto be active, or can it work alone (as in the B&R mapp UserX tutorial video)? - Where is the password for a user stored, and how do I check that it matches what I type in
sPassword?
I can attach screenshots of the Watch window, the configuration and Global.var if that helps.
Thank you for your help.

