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

How to write trigger to create contact?
hey all,
i need help in my trigger. I have a object:additional_contacts__c
it has a field contact__c which is a lookup to Contact object.
if the users cannot find any contacts then they have to create one contact.
I have no good experience working on triggers.Can anyone please help me how to write a trigger for this
i need help in my trigger. I have a object:additional_contacts__c
it has a field contact__c which is a lookup to Contact object.
if the users cannot find any contacts then they have to create one contact.
I have no good experience working on triggers.Can anyone please help me how to write a trigger for this
Triggers can be tricky to learn at first. Try reading up on them in the documentation (https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_triggers.htm). For your situation I recommend doing something like this.
This is a template/example of what you can do without any knowledge of required fields and other triggers in your org.
Hope this helps!
AM