I am trying to define access rights to web visualisation trough Codesys programing interface with right mouse button over the object (e.g. PLC_VISU) -> Object properties -> Access rights. I am defining different passwords for different groups, but no matter what I do, when I try to access via web interface, it never asks for user name / password and I have full access to all objects.
J think you have to declare somes variables, for example :
CurrentUserLevel: INT := 1;
CurrentPasswords: ARRAY[0..7] OF STRING := 'aa','bb','cc','dd','ee','ff','gg','hh';
VisuDoExecuteUserlevelInit: BOOL := FALSE;
CurrentUserLevel : level of password you want to set on start
CurrentPasswords : Array, 8 levels of password
Then you can change User or Password by program, or in the pages of display you can add buttons.
Add a button, and configure :Category -->Input -->Execute program
Hoping to help you, sincerely.
Thank you JAPIB
I tried with these declarations, but the result is the same.
I forgot to say that all access restrictions work well in CoDeSys -> Visualisation interface, but in the web interface all items are available without any passwords. No matter with or without declarations for CurrentUserLevel, CurrentPasswords....
3S-Software has made an example for this. Go to their website and click on Download => CoDeSys Sample Projects.
Through this ftp site go to Projects/CoDeSysV2.3/Visualisation/LoginDemo_XML/.
This shows you how to handle a login through the web.
Hi! where I can find some information about CurrentUsername and INTERN statement? I haven't found in the COdesys Help. May there is a tutorial online...
THanks a lot.
Log in to post a comment.