Set value for field from another model when adding a row

Hmmm Could you post an example,   I am trying that but not getting any results that way.