Create New Opportunity And Opportunity Product Records Using Existing Price Book Entry Records (Pre-Fill)

In this guide, we will explain how to create new Opportunity records with Opportunity Line Items on Salesforce using Formyoula. We will use the Salesforce lookup field to search for existing Price Book Entries and create new Opportunity Line Items that will be linked to the Opportunity record.

We will be able to use this form while our mobile device is offline. All records will be created on Salesforce once the device has regained internet connection.

Please start by following the steps below:

1. Go to Formyoula.com and click “Sign In”.

image

2. Please click on the “New Form” button to create a new form.

image

3. Please click “Rename” to give your new form a name.

image

4. We will drag and drop all required Opportunity object fields on our form. A Salesforce lookup field to search for existing Account records that the Opportunity record will be linked to, a Text field for the Opportunity Name, a Date field for the Close Date and a Select field for the Stage.

image

5. Next, please drag and drop a Hidden field onto your form that will hold the Price Book ID. Please copy the Price Book ID from your Salesforce Price Book record detail page URL. This will link the new Opportunity record to an existing Price Book so that we can create Opportunity Line Items from the Price Book Product list.

image
image

6. Next, please drag and drop a Repeat Group field on your form. This will be used to create any number of new Opportunity Line Items that will be linked to the new Opportunity record.

image

7. Please drag and drop all required fields inside the Repeat Group for the Opportunity Product record creation. First, drag and drop a Salesforce Lookup and edit the field.

Please add a record filter option to search for Price Book Entry records linked to a particular Price Book in Salesforce. For example:

  • Pricebook2Id = ‘01s58000000Hezx’
image

8. Please drag and drop all the other necessary fields for the new Opportunity Line Item record creation.

image

9. Once done, please click “Save & Close” to save your form.

image

10. Next, please click on “(Add)” under the “Connections” column or click on the “Create a Connection” button, or select “Add/Edit Connections” from the “Actions” available list.

image

11. Select “Salesforce” from the available connections list and click “Create Connection >>”.

image

12. Please select “Opportunity” from the available Salesforce Object list and click “Save”.

image

13. Select the matching fields from both mapping select lists and click “Create Map”.

image

14.  Once done, please click on the “<< Back to Connections” button.

image

15. Select “Salesforce” from the available connections list and click “Create Connection >>”.

image

16. Select “Opportunity Product” from the available Salesforce Object list and click “Save”.

image

17. First, we will enable the Repeat Group function that will make sure that each Formyoula Repeat Group entry is created as a new record on Salesforce.

image

18. Please save the record settings once done.

image

19. First, please map the [New Opportunity Record ID (Seq 1)] field to the Opportunity ID field in Salesforce. This will make sure to link the New Opportunity Line Item records to the new Opportunity record.

image

20. Next, please select all the other matching fields from both mapping select lists and click “Create Map”.

image

21.  Once done, please click on the “<< Back to Connections” button.

image

22. Select “Salesforce” from the available connections list and click “Create Connection >>”.

image

23. Select “Price Book Entry” from the available Salesforce Object list and click “Save”. This connection will be skipped and used only for Product record Price field pre-fill.

image

24. First, we skip the connection based on the Price Book Entry Salesforce Lookup field.

image

25. Next, we will use the “Use Repeat Group” function for this connection as well. This is required if we will be pre-filling multiple repeat group line items.

image

26. Please save the record settings once done.

image

27. Next please map the Price Book ID and Price fields to the matching Salesforce fields.

image

28. Once done, please click on the blue form name link to go back to the form builder.

image

29. Please click on the “pencil” icon on the Salesforce Lookup for the Price Book Entry records. Scroll to the bottom and please select the “Create Price Book Entry Record” connection ID. This will be used for the Price field pre-fill.

image

30. Please apply the changes and save the form.

image

31. Please click on the “Try” button next to the form, this will open the mobile web app.

image

32. Please select your newly created form.

image

33. Please capture all the necessary fields for the new Opportunity record creation.

image

34. Please click on the “Add Opportunity Line Items” button to create as many Opportunity Line Item records as necessary. By searching for the Price Book Entry record, it will automatically pre-fill the Price field. Once done, please submit the form entry.

image

35. When you open your Salesforce, you will be able to see the newly created Opportunity record with multiple Opportunity Line Items that are linked to your selected Account record.

image

For any questions, please contact us - [email protected]