Generates a subTransaction based event.
It retrieves the transaction status based on the referenced main transaction status and uses the subTransaction error code.