• Ron La Porte 7
  • NEWBIE
  • 0 Points
  • Member since 2016

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 2
    Replies

I have searched high and low for someone who has done this and have come up empty handed. I find it hard to believe this is not a common issue.

 

As you know, if an Opportunity is added to a Contact, the Contact is automatically added as a Contact Role on that Opportunity. It does not make them the Primary Contact Role or define the Role, but it does add them.

 

If an Opportunity is added to a Person Account, the Contact/Person Account is not automatically added as a Contact Role on the Opportunity. When the Opportunity is created there are no Contacts listed.

 

What I would like to do is to have a trigger that automatically adds the Person Account as a Contact to the Contact Roles when an Opportunity is created under them. I would like for them to be made Primary and a role of Decision Maker. 

 

It seems to me that adding Contact Roles automatically would be more common, but I guess not. Has anyone found a solution to this that they can share? Thank you everyone!

 

Dusty

Opportunity has two fields I want to reference in another custom object, Owner and CloseDate.  For CloseDate I created a formula field returning a date and simply referenced the date field using Opportunity__r.CloseDate.  I tried the same method for Owner.  I created a formula field returning text and referenced the owner with Opportunity__r.Owner.  The former works.  The latter gives a syntax error stating Owner is not a field.

 

When I check the Opportunity object it says the field name is "Owner".  What is wrong?  A possible clue is that Owner is data type Lookup(User).