cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X

Do editability rules apply to a trigger's assignment tab values?

bcollins-2
10-Marble

Do editability rules apply to a trigger's assignment tab values?

I'm working on solving an issue in our configuration, but I've run into a strange behavior. I would assume that all values set on the assignment tab of a trigger would be done regardless and ignore editability rules, as that is the behavior when setting values from inside a script. However, even though I have confirmed the suspected trigger is running, it doesn't appear to be doing its job. So I want to try to confirm or dispute the most likely reason: are the values not getting set because the assignment tab does not have the permission to change an uneditable field?

Any additional information about exceptions to editability rules would be appreciated as well. Thank you.

ACCEPTED SOLUTION

Accepted Solutions

Yes, the values set through the assignment tab of a trigger do ignore editability rules (actually, it's the triggers that do).

Are you absolutely sure your trigger executes, or that another one doesn't run after to undo the results?

I've had that happen to me and it's easy to have other triggers run and somehow cause the rule to not be met or the field to be changed again.

There's one more wrinkle in my opinion: the PRE/POST switches don't apply to triggers that do assignments. For that reason, I avoid them as much as possible. Instead, I use a trigger script that does field assignments.

With this solution, I can 1) enable/disable triggers by checking/unchecking PRE/POST and not mess my rules; and 2) use my own logging functions for debugging.

View solution in original post

1 REPLY 1

Yes, the values set through the assignment tab of a trigger do ignore editability rules (actually, it's the triggers that do).

Are you absolutely sure your trigger executes, or that another one doesn't run after to undo the results?

I've had that happen to me and it's easy to have other triggers run and somehow cause the rule to not be met or the field to be changed again.

There's one more wrinkle in my opinion: the PRE/POST switches don't apply to triggers that do assignments. For that reason, I avoid them as much as possible. Instead, I use a trigger script that does field assignments.

With this solution, I can 1) enable/disable triggers by checking/unchecking PRE/POST and not mess my rules; and 2) use my own logging functions for debugging.

Announcements


Top Tags