Automation Champion

Automating Salesforce One Click at a Time
Automation Champion
  • Home
  • About Me
    • Testimonials
    • Resources
  • Process Builder
  • Salesforce Flow
  • Pardot
  • Apex
  • Training Details
    • Salesforce Administrator
    • Salesforce Advanced Administrator
    • Platform App Builder
    • Lightning Flow
    • Pardot
    • Sales Cloud
    • Service Cloud
    • Community Cloud
    • Hands-on Excercises
  • My Books
  • Contact Me
  • Tag: how to create workflow in salesforce

    • Trigger On Opportunity Team Member

      Posted at 8:30 PM by Rakesh Gupta, on September 19, 2013

      Opp Team Member Task assignment

      An opportunity team is a set of users that normally work together on sales opportunities. A typical opportunity team might include the account manager, the sales representative, and a pre-sales consultant. As soon as you assign members in your Opportunity team and if you want to assign some task to them, So you can’t achieve this by using Workflow because there is no such option for task assignment / New Task for ‘Opportunity Team Member‘.

      No Option to assign task

      No Option to assign task

      To achieve this you have to write Apex trigger. Below is the sample code you can modify it according to your requirement.

      trigger TaskOnOppTeamMember on OpportunityTeamMember (after insert) {
      list<Task> NewTask = new list<Task>();
      if(trigger.IsInsert)
      {
      for(OpportunityTeamMember oppTeam : trigger.new)
      {
      Task tasksInsert = new Task();
      tasksInsert.WhatId = OppTeam.Opportunityid;
      tasksInsert.OwnerId = oppTeam.Userid;
      tasksInsert.Subject = 'Great Daddy';
      tasksInsert.ActivityDate = date.today();
      tasksInsert.Priority = 'Normal';
      NewTask.add(tasksInsert);
      
      }
      }
      Database.insert(NewTask);
      }

      Now navigate to your opportunity detail page Under Opportunity Team related list Click on “Add” Button.

      Opp Team Add Button

      Select the User Name, Opportunity Access, and Role and click on”Save” button. Now navigate to Open Activity related list and cheers.

      Task Assign

      Posted in Apex | 3 Comments | Tagged ADM 201, Con 201, Count records in a related list, DEV401, how to create workflow in salesforce, Istest in salesforce, online trainer, Opp team, opportunity team member, salesforce interview question, Salesforce opp team member, Salesforce opportunity team, Salesforce opportunity team member, salesforce workflow rule, Salesforce.com Certified Force.com Developer, salesforce.com certified force.com developer exam, salesforce.com certified force.com developer questions, Task on Salesforce opp team member, task on Salesforce opportunity team, Task on Salesforce opportunity team member
    • Add new button on list view

      Posted at 6:36 PM by Rakesh Gupta, on September 15, 2013

      New Button

      Many times you come across the requirement to add button on list view page for some objects ( Here I am talking about Account Object).

      Export To Excel

      Export To Excel

      To Add button like I mentioned in the above screenshot, Navigate to Name | Setup | App Setup  |Customize | Accounts | Buttons, Links and Actions and then click on New Button or Link. Fill details, you can take help from below screenshot.

      Export To Excel Button

      Export To Excel Button

      Fill the form Label, Name, In Display Type Select “List Button”, Select Behavior as per your choice and in Content Source Select VisualForce Page that you want to open when you click on this button then Click on Save.

      Next add this button to list view, to do this Go to “Search Layouts” for Accounts, then edit ” Accounts List View ” and add “Export To Excel” button to selected list buttons.

      Add button to list view

      Add button to list view

      Now navigate to Account Tab and cheers….

      Posted in Sales cloud | 3 Comments | Tagged Add new button on list view, ADM 201, Con 201, Count records in a related list, dev 401, DEV401, how to create workflow in salesforce, Istest in salesforce, List view in salesforce, online trainer, sales, sales cloud consultant, salesforce admin certification practice exam, salesforce Admin exam, salesforce administrator exam, salesforce administrator tutorial, salesforce certified developer exam, Salesforce online trainer, salesforce trainer, salesforce training material, salesforce.com certified force.com developer exam, sfdc online trainer
    ← Older posts
    • Search

    • Upcoming Trainings

      Salesforce Administrator Certification
      Salesforce Advanced Administrator Certification
      Salesforce Platform App Builder Certification
      Lightning Flow & Process Builder
      Advanced Lightning Flow
      Pardot Specialist & Consultant Certification
      Sales Cloud Consultant Certification
      Service Cloud Consultant Certification
      Community Cloud Consultant Certification
    • Sponsor #1

    • Sponsor #2

    • Sponsor #3

    • Sponsor #4

    • Order Now!

    • Buy My Book

    • Buy My Book

    • Recent Posts

      • Getting Started with Salesforce Flow – Part 59 (Clone a Chatter Group with Members)
      • New Research: Salesforce Delivery Teams Excel in Speed but at the Expense of Quality
      • Improve Your Data Collection Strategy with Web Forms
      • Getting Started with Salesforce Flow – Part 58 (Customize Previous, Next, Finish, and Pause Button Label for Screen Flow!)
      • Advancing Business Operations with Salesforce and QuickBooks
    • Salesforce ID Converter Build on Lightning Flow

      Converting 15 digit ID to 18 digit Salesforce ID
    • Blog Archives

    • Categories

  • Information

    • About Me
    • Affiliate Disclaimer
    • Contact Me
    • Privacy Policy
  • Top Posts

    • Learning Flow
    • Learning Process Builder
    • Getting Started with Salesforce Flow – Part 43 (Dynamic Approval Routing in Salesforce)
    • Getting Started with Salesforce Flow – Part 57 (Adding Validation to Flow Screen Components)
    • Getting Started with Salesforce Flow – Part 59 (Clone a Chatter Group with Members)
    • Getting Started with Salesforce Flow – Part 11 (Count Number of records in a Record Collection Variable)
    • Getting Started with Salesforce Flow – Part 1 (Understand, Create & Use Variables in Flow!)
    • Getting Started with Salesforce Flow – Part 24 (Automatically Assign Permission Sets to New User)
    • Salesforce Spring’21 Release Quick Summary
    • Getting Started with Process Builder - Part 1 (Automatically Create a record)
  • Social Media

    • View Automationchampion’s profile on Facebook
    • View Automationchamp’s profile on Twitter
    • View Rakeshistom’s profile on GitHub