Update the value of a related field using a Record relationship

Certified Associate Developer

So, i want to update a related field of a record, that contains an array of records. Im trying to do it by using append, but no values are stored into the field.  

Anyone knows if there is a way to achieve this? Doing it in the initialization of the object works, but i need to update it on demand.

thank you very much!.

  Discussion posts and replies are publicly visible