How to assign credit hours to user account once the content is marked completed by admin
i managed to do it with rules and adding some action code in a custom module.



After adding a condition, i had a make a custom action and then i was able to add that action in to the created rule.

You can send value to your custom action and then load user and update its field.

$user = user_load($user_trainer_id);
$obj = entity_metadata_wrapper('user', $user);
$obj-&gt;field_earned_credit_hours = $new_custom_value;
$obj-&gt;save();