URLs and Formula Fields & Buttons

You are here:
< Back

Setup

Once you have built a form, just head over to the URL Builder and click on the button “Copy to Clipboard” to copy the URL for the form. This By substituting the value part of the parameter, you can tell 3B Forms to pull information from a specific record. For more information, please refer to the article Pre-populate from Existing Record to learn more about how to use the facility.

Note:

  • The default URL will contain the Object’s ID field with a value [XXXX]. If you put a custom value here, it will look different than the screenshot above.
  • You can customze the URL Key to be different than the default key. It is a good practice to change it to something, your users wouldn’t suspect is the ID of a record in Salesforce

Button Merge

You have built a form that Internal Salesforce Users will need to use. This is a form that guides Sales Representatives to log Phone Call information – it contains a few fields such as “Asked the customer if they need a new Kettle”. You want Sales Reps to create those Phone Logs against a Lead Record, so you need a button on the Lead Object which will launch the form.

To achieve this, head over to Setup and search for “Lead” in the Quick Find box. Click on Buttons, Links or Actions  option and hit “New Button or Link”

  • Display Type: Select the option “Detail Page Button”
  • Behaviour: Display in new window
  • Content Source: URL

In the text field, paste the link for the form that you copied earlier.

Your url will something similar to this https://simple-forms-developer-edition.eu9.force.com/site1/apex/formcomplete?id=a000O00000xQrpeQAC&LeadId=[XXXX]. What you need to do is replace the [XXXX] part with a dynamic Lead ID. Use the Select Field Type to be Lead and Insert Field  as Lead ID and you should get something like this : {!Lead.Id}.

The end result will look something like this:

https://simple-forms-developer-edition.eu9.force.com/site1/apex/formcomplete?id=a000O00000xQrpeQAC&LeadId={!Lead.Id}

 

 

Formula Merge

You have built an Application Form for candidates to apply for jobs in your company. Sometimes, however you want to amend slightly the details of the application form on behalf of a candidate. You want your internal salesforce users to have a an option on the Contact record to click on a link and amend the details of the already submitted aplicaiton form

To achieve this, head over to Setup and search for “Contact” and click on “Fields” option. Click on “New” to create a new field and select “Formula” as the field type.

Click “Next” and select “Text” as the Formula Return Type

In the editor, select the function HYPERLINK and populate it as follows:

HYPERLINK("https://simple-forms-developer-edition.eu9.force.com/site1/apex/formcomplete?id=a000O00000xQrpeQAC&ContactId=[XXXXX]",
 "Application Form")

Whats left is for you to substitute the [XXXX] part with the Contact’s ID :

HYPERLINK("https://simple-forms-developer-edition.eu9.force.com/site1/apex/formcomplete?id=a000O00000xQrpeQAC&ContactId=" & Id,
 "Application Form")

You can surround Salesforce formulas with complex logic, for example, to open a different form depending on the stage of the applicant. Please refer to the Salesforce documentation on Salesforce formulas.