• Adrienna Tiller
  • NEWBIE
  • 0 Points
  • Member since 2016

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 2
    Replies
I would like to create a custom button on the Open Activities related list of the Opp. The button would function the same as the New Event button, but it would take them to a different layout for a certain type of event layout. I have created the button, but I don't know what code to use on the url to take it to the custom page I want.
I cannot send emails to leads due to a trigger error:
trigger TaskTrigger on Task (before insert) {
  TaskTriggerHandler handler;
  
    if (trigger.isBefore && trigger.isInsert) {
        handler = new TaskTriggerHandler(Trigger.new);
        handler.launch();
   
As per the debug log it states that there is some trigger on task which is causing the error. However if you deactivate the trigger the send an email standard functionality should work fine.

Trigger on Tasks (https://hew.my.salesforce.com/01q370000006A8Y) which tries to set the Task WhatId (e.g. the "Related To" field).
"Related To" can not be populated on a Task where the WhoId (e.g. Name) is a Lead. The attempt to populate WhatId on a Task related to a Lead causes an expected error.
 
I would like to create a custom button on the Open Activities related list of the Opp. The button would function the same as the New Event button, but it would take them to a different layout for a certain type of event layout. I have created the button, but I don't know what code to use on the url to take it to the custom page I want.
I cannot send emails to leads due to a trigger error:
trigger TaskTrigger on Task (before insert) {
  TaskTriggerHandler handler;
  
    if (trigger.isBefore && trigger.isInsert) {
        handler = new TaskTriggerHandler(Trigger.new);
        handler.launch();
   
As per the debug log it states that there is some trigger on task which is causing the error. However if you deactivate the trigger the send an email standard functionality should work fine.

Trigger on Tasks (https://hew.my.salesforce.com/01q370000006A8Y) which tries to set the Task WhatId (e.g. the "Related To" field).
"Related To" can not be populated on a Task where the WhoId (e.g. Name) is a Lead. The attempt to populate WhatId on a Task related to a Lead causes an expected error.