Reset password while termination.

Hi Team,

I have a use case to reset password of ADSAccount after termination.

I have updated the on saving script of ADSAccount with below piece of code to reset password of ADSAccount.

CCC_CustomBool01 is a custom column in person table which gets true while user gets terminated.

This piece of code does not get executed after user gets terminated. Does on saving scripts read foreign key references in 1IM?

'generate password for off-boarding
'when not manual set
'and configparm "TargetSystem\ADS\Accounts\NotRequirePassword" is not set
If $[IsLoaded]:Bool$ _
AndAlso Not CBool(Variables("FULLSYNC")) _
AndAlso $FK(UID_Person).CCC_CustomBool01[C]:Bool$ And $FK(UID_Person).CCC_CustomBool01:Bool$ _
AndAlso Connection.GetConfigParm("TargetSystem\ADS\Accounts\NotRequirePassword")<>"1" Then
Entity.PutValue("UserPassword", TSB_GetPassword (entity, "UserPassword", "ADS", $FK(UID_Person).CentralPassword$, True))
End If