This is what I use to create the user:
$new_user = array( 'name' => $form_state['values']['email'], 'status' => 1, 'access' => REQUEST_TIME, 'roles' => array(), ); user_save('', $new_user);
Now I want to add values to the field collection items.
I have a field collection called
field_personal_details and a field collection item called
field_firstname, but I have no idea how to access it. Can someone help me get started?