Hi,
I have to update a status value after a related record action but it is not getting updated until unless I refresh the screen manually.
I have used a!refreshvariable() for the local variable where we fetch the status, have given activity chaining in the Process Model and also tried Records sync Smart service.
But none of them works. Can someone help if missing something or is there any other option that causing this.
Discussion posts and replies are publicly visible
Hi p2005,
I recommended to check activity chaining again if it missed in any path or exceeding the allowed limit. Default limit is 50 nodes.
You can add screenshot of the PM for better clarity.
Activity chaining is present even in the sub-processes too and it is small PM.
Did you configure the refreshVariable in such a way that it would refresh after the related action is performed? refreshAfter parameter to be configured as "RECORD_ACTION"
Provide more details from the interface code please.
local!status: a!refreshVariable( value: rule!RGRACSLBL_getTaskStatusUsingLabelChangeCountryId( labelChangeCountryId: ri!labelChangeCountry['recordType!{d1de8e89-4208-44d3-bb27-0306902c0671}RGRACSLBL Label Change Country.fields.{6c137b66-e39e-49a8-b443-3728d8ccd6a4}id'], taskName: cons!RGRACSLBL_TEXT_PLL_TASK_TYPES[6] ), refreshAfter: "RECORD_ACTION" ),
this is the rule to fetch the status and it has refresh variable as you mentioned.
but it only gets updated when refresh the screen manually
Can you also paste the code of RGRACSLBL_getTaskStatusUsingLabelChangeCountryId rule?
Is this rule using localvariables and not getting refresh on "RECORD_ACTION"?
refreshOnVarChange try this in your a!refreshVariable
Harsh Kumar Agarwal said:Is this rule using localvariables
yeah, this is my suspicion as well.
Yes, it is using local Variables and all the local variables have a!refreshVariable()
Can you paste the code of RGRACSLBL_getTaskStatusUsingLabelChangeCountryId?
OR
You can create a query in main rule using refreshVariable with property refreshAfter: "RECORD_ACTION". If this works then you will get your answer.
p2005 said:all the local variables have a!refreshVariable()
This needs to be configured very carefully or else it won't work (remember that refreshVariable() variables default only to "refresh on referenced variable change", and this applies even to ones found in expression rules). Hence why HarshKumar is asking you to paste the code in question.