You need to sign in to do that
Don't have an account?

Not sure if I need a workflow rule or trigger - Can you help?
We want to build reports using email addresses of contracted opportunities. We can do this through the "Contact Roles" in Opportunities. However, it is not required so very few of our users follow my instructions to fill it out.
1) Is it possible to design a workflow rule where if an opportunity is created and saved, the user must fill in something in the Contact Roles section?
2) If not - We have a lookup field in opportunities called Primary Contact (looks in Contacts tab for appropriate person). Below that, I created a field called "Primary Contact Email". Is it possible to design a trigger where if a name is inserted into the Primary Contact field via the lookup, the email address of that contact will automatically be pulled into the field "Primary Contact Email"
Thank you for any help you can provide!
To answer your questons, though --
1. Yes, but look at "validation rules." It's an easy way to prevent a record from being saved unless certain conditions are met (like all the fields are filled in).
2. Yes, definitely.
(Workflow and triggers are the same idea -- automated tasks that run after you press "save" on a new or updated record -- with the difference being that the former is both simple and rather limited, and the latter is complicated but very flexible.)
Mike,
Thank you for your thoughts. I went to Security Controls but Contact Roles is not on the list since it is a related list and not a field in Opps.
I have found that you can't do a validation rule for a related list. So I'm left with workflow and triggers.
I've experimented with both. I will try to track down some workflow code that is able to replicate what I need to do...
The code is:
Glad to know it helped you!
Message Edited by jrotenstein on 10-17-2008 06:13 AM
John,
Awesome info! That was exactly what I was looking for...Thank you for your help....
Devon