Friday, January 24, 2014

Salesforce: Phone call from Smartphone

This blog is not related to Salesforce1 platform or mobile app promoted in Dreamforce '14. But, we have a use case, when user would like to call a number using smart phone or tablet when browsing from website.

Here is the scenario, sales rep would like to call a Contact in Salesforce. Rather than to remember or copy the number to a paper, can the sales rep call directly from Salesforce webpage since he use his smart phone to browse Salesforce?

Phone field in Salesforce is not click-able, so by default, there is no way to call from Salesforce website. But, we have the workaround to use a formula field.

So, here we go:
  • Example to use standard Phone field in Contact object 
  • Create a formula field with return type = Text
  • Use this formula = HYPERLINK("Tel:" & Phone, Phone )
  • Add the formula field to Contact page layout, you may remove the default Phone field from page layout to avoid confusion
User will see this new field in page layout and it is click-able. Screenshot below taken from when user click the Phone formula field.