Security setting for boolean tags with popup message "Action Denied"

I’m trying to restrict the access to the boolean tag with user role and have popup like below;

image

as of now i’m able to restrict the boolean tag but not getting popup message.

I don’t think there is any avenue to use the built-in notifications for what you want.

The reason we can do that with components is because we have the context of the component and can therefore log what (the component) is trying to do (onMouseUp) when the access was restricted. In this case, the component has an expected shape (ie: properties), and we can obtain what we need for logging.

But when a tag checks access, the request could come form a component, or a change script, or a project script, or a binding on a session property, or a Message Handler Script… There are too many avenues for us to realistically print a usable message.

You could build you own Popup to mimic the appearance of our notification banner pretty easily, and you could open/close that popup based off of whatever event is modifying the tag.