Hi Bill,
The status of the Order Close entity will always be complete even for a cancelled Sales Order so it is a bit of a red herring. The correct way to do this would be to register a plugin on the Pre/Post Sales Order Update plugin and check whether the statecode/statuscode
is changing and then apply your logic there. It is strange that this operation goes through an Update operation and not a SetState/SetStateDynamicEntity but the whole Sales process works a bit differently to other entities.
The Sales Order Update plugin will fire after the creation of the Order Close so you can query it or the Sales Order in your logic if needed.
Michael Palmer
xRMPalmer
Follow @MJFPalmer
Rockstar365