You need to sign in to do that
Don't have an account?
David Bloomy Bloom
apex trigger execute a custom button when a field changes from False to True
Hi, I am looking for assistance to write an apex trigger to execute a cusom button on my custom object when I change the state of a check box (via apex loader) from false to true.
My custom field is First_Email_Sent__c and my custom button is Conga_First_Email My custom object is called Sabre_Hotels (Sabre_Hotels__c)
thanks you in advance for any assistance.
David
My custom field is First_Email_Sent__c and my custom button is Conga_First_Email My custom object is called Sabre_Hotels (Sabre_Hotels__c)
thanks you in advance for any assistance.
David
The above URL is launching an email composer. Unfortunaltely, this is not possible using apex triggers. Apex triggers are not interactive in nature and hence the above functionality cannot be achieved using triggers. Also, going by your requirement, you are setting a checkbox to true or false from a dataloader, so i assume it will be bulk data processing, so i dont think its realistic to open email composers for all the records.
You can use triggers if you want to send automated emails to if you conditions are met.
All Answers
Hope this clarifies.
Please mark it as best answer if it answers your question. It helps others.
Here is the code from the custom button:
https://composer.congamerge.com
?sessionId={!API.Session_ID}
&serverUrl={!API.Partner_Server_URL_290}
&id={!Sabre_Hotels__c.Id}
&ReportId=00O9000000793dm?pv0={!Sabre_Hotels__c.Name}
&EmailToID=0039000000B4Z9N
&EmailAdditionalTo={!Sabre_Hotels__c.Hotel_Email_Address__c}
&CETID=a0J9000000U4KIK
&TemplateId=a0L9000000DB1Te
&AC0=1
&SC0=1
&_DS7=9
&DS7=1
&QMode=3
The above URL is launching an email composer. Unfortunaltely, this is not possible using apex triggers. Apex triggers are not interactive in nature and hence the above functionality cannot be achieved using triggers. Also, going by your requirement, you are setting a checkbox to true or false from a dataloader, so i assume it will be bulk data processing, so i dont think its realistic to open email composers for all the records.
You can use triggers if you want to send automated emails to if you conditions are met.
David