How can we help you today?

Using CheckAccess() with Embedded Mimic Parameters in Geo SCADA for Evaluating User Permissions

In Geo SCADA Expert, the CheckAccess() method can be used within mimic expressions to determine whether the currently logged-in user has a specific permission on a database object. This is particularly useful when you need to dynamically show or hide mimic objects based on user security rights.

Common permission codes include:

  • RD = Read
  • BRS = Browse
  • CTL = Control
  • OVR = Override
  • CFG = Configure
  • SEC = Security
  • ADM = System Administration

The CheckAccess() method returns:

  • True if the user has the specified permission
  • False if the user does not have the specified permission

Standard Visibility Control

A common use case is controlling an object's Visible property based on a user's permissions.

For example:

IIF(".Point with particular security settings.CheckAccess('CTL')", 1, 0)
In this example:
  • Visible is simply the property being animated.
  • CTL (Control) is used as an example permission code.
  • If the logged-in user has the specified permission, the expression returns 1 (visible).
  • Otherwise, it returns 0 (hidden).

The same approach can be applied to other properties and permission codes depending on the intended behavior.

The Challenge with Embedded Mimics

When creating reusable embedded mimics, object references are often passed through parameters.

For example, a mimic parameter may be defined as:

Parameter:Point.ObjectLink

An initial attempt might be:
IIF("Parameter:Point.ObjectLink"+".CheckAccess('CTL')",1,0)

However, this does not work as expected because the parameter is treated as a string rather than an object reference.

As a result, Geo SCADA does not evaluate the CheckAccess() method against the target object.

The Correct Solution: Indirect Expressions

To evaluate CheckAccess() against a parameterized object, an indirect expression must be used.

The following syntax allows Geo SCADA to evaluate the constructed object reference at runtime:

Example:

["Parameter:Point.FullName" + '.CheckAccess("CTL")']
The square brackets instruct Geo SCADA to evaluate the assembled string as an expression.
Example text animation:
CheckAccess

The parameter will:

  • Be visible when the user has CTL access.
  • Be hidden when the user lacks CTL access.

Schneider Electric Indonesia

Users group

Discuss this topic with experts

Visit our Community for first-hand insights from experts and peers on this topic and more.
  • Products Documentation
  • Software Downloads
  • Product Selector
  • Product Substitution and Replacement
  • Help and Contact Centre
  • Find our Offices
  • Get a Quote
  • Where to buy
  • Schneider Electric Community
  • Careers
  • Company Profile
  • Report a misconduct
  • Accessibility
  • Investors
  • EcoStruxure
  • Job Search
  • Blog
  • Legal information
  • Privacy Policy
  • Cookie Notice
  • Terms of use
  • Change your cookie settings