8.4 Exercise
This section explains the basics of the feature. Please utilize the feature according to your site environment. |
Exercise: User Login and Access to the Object
In this example, you will add a user to the project and assign a security level. Then, you will configure the accessibility of the control functions in the Xpanel project.
(1) Adding a user
a) Go to [Tools] β [Security] and press the [New User] button to bring up the [Security Properties] window.
b) Set the user ID to βAβ and the password to β1234β. Set the userβs security level to 8.
c) Press [OK] and you will see the new user added to the list.
(2) Configuring Objects with Security Level
a) Create an analog tag named βRUNβ in the database.
b) Select [Draw] β [Dynamic Tag] and add the object to the graphic page. Then assign the βRUNβ tag to the object as shown below.
c) Create an object to write the value of the βRUNβ tag. Label it with a text object βLevel 10β and group the objects. Then set the action as βWrite Tag Valueβ within the βTouchβ feature. Enter 10 in the βValueβ field.
d) Go to the [Security] tab and set the Security Level to 10.
e) Create another object to write the value of the βRUNβ tag. Label it with a text object βLevel 5β and group the objects. Then set the action as βWrite Tag Valueβ within the βTouchβ feature. Enter 5 in the βValueβ field.
f) Go to the [Security] tab and set the Security Level to 5.
g) Create an object as shown below to log on after the project execution.
(3) Checking the Operation
a) Execute the project with Xpanel or run the simulator. Press the βLogOnβ object and then press the βLevel 10β object. Since the userβs security level is 8, the object cannot be operated. The following message will appear.
b) When you press the βLevel 5β object, the value will be written to the tag value object since the userβs security level is higher than level 5.
Β