How to do it...

Carry out the following steps to create a custom Help for this Page option on an opportunity record using a Lightning Component, Lightning Action, and a PDF document:

  1. Click on the Setup gear icon, as shown in the following screenshot:

The Setup gear icon is located in the top right-hand area of the main Home page.

  1. Click the Developer Console option, as shown in the following screenshot:

We will be presented with the Developer Console window.

  1. Click on File.
  2. Click on New.
  3. Click on Lightning Component, as shown in the following screenshot:

We will be presented with a New Lightning Bundle dialog.

  1. Enter OpportunityHelp in the Name field.
  2. Optionally, enter a value in the Description field.
  3. Click on Submit, as shown in the following screenshot:
  1. In the resulting component page, paste the following code:
 
<aura:component implements="force:lightningQuickAction"> 
  <a href="{!$Resource.HelpText}" target="_blank">
Help for This Page (New Window)
</a> <iframe width="100%" height="400px;" style="border: 1px solid"
src="{!$Resource.HelpText}" /> </aura:component>
  1. Click on File.
  1. Click on Save, as shown in the following screenshot:

We will now configure a Lightning Action that references the component.

  1. Click on the Setup gear icon, as shown in the following screenshot:

The Setup gear icon is located in the top right-hand area of the main Home page.

  1. Click the Setup option, as shown in the following screenshot:
  1. Navigate to the Opportunity customization setup page, by clicking the following: Objects and Fields | Object Manager | Opportunity | Buttons, Links, and Actions.

Locate the Buttons, Links, and Actions section on the right of the page.

  1. Click on New Action.

We will be presented with the Opportunity Actions - New Action page.

  1. Select Lightning Component for the Action Type.

We will be presented with the Lightning Component selection.

  1. Select c:OpportunityHelp from the Lightning Component selection.
  2. Enter 500px in the Height textbox.
  3. Enter Help for this Page in the Label textbox.
Upon clicking out of the Label textbox, the Name automatically changes to Help_for_this_Page.
  1. Optionally, enter a value in the Description textbox.
  2. Click on Save, as shown in the following screenshot:

We will now modify an opportunity page layout to add the Help for this Page Lightning Action to the opportunity record page:

  1. Click on the Setup gear icon, as shown in the following screenshot:

The Setup gear icon is located in the top right-hand area of the main Home page.

  1. Click the Setup option.
  2. Navigate to the Opportunity customization setup page, by clicking the following: Objects and Fields | Object Manager | Opportunity | Page Layouts.
  3. Select the required page layout by clicking on the page layout name from within the list of available page layouts, as shown in the following screenshot:
  1. Override the predefined Actions in the Salesforce Mobile and Lightning Experience Actions section by clicking on override the predefined actions, as shown in the following screenshot:
  1. Drag the Help for this Page Lightning Action to the Actions section on the page layout, as shown in the following screenshot:
  1. Finally, click on Save.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset