Salesforce Call Center tips: Display Call Duration in Minutes

In this post we showed you how to add Call Duration to a Salesforce Activity page.  Unfortunately, the only existing field available for you to add and display on your Activity page gives you call duration in seconds.  That might work just fine for you and your organization, but some of our users wanted to display call duration in minutes.  Here’s how to do it.

As the Salesforce Administrator, navigate to Setup-> Customize-> Activities -> Add Custom Fields.

Select New:

Select Formula for your data type and then click Next:

Enter in the name you would like to give the field (Sarah used “Call Duration(Min)” here.  Then select Text and then Next:

Click Advanced Formula and then copy and paste the text below this image into the highlighted space shown below.  Once you’ve pasted it, click Next:


IF((MOD(CallDurationInSeconds/60,1)*60) > 10,

TEXT(FLOOR(CallDurationInSeconds/60)) + “:” + TEXT(FLOOR(MOD(CallDurationInSeconds/60,1)*60) ),
TEXT(FLOOR(CallDurationInSeconds/60)) + “:0” + TEXT(FLOOR(MOD(CallDurationInSeconds/60,1)*60) ))

Select the profiles you wish to be able to see this field.  Finally, click Save.

Navigate to a task and you should now see “Call Duration (Min)” displayed on that task page.  Cool!

In the image above, you can now see that we’ve got two Call Duration Fields;  one displays duration in seconds (we showed you how to display in this post) and one outlined in red that displays call duration in minutes (this is the custom field we just created).

If you’d also like to see this field on your Contacts’ Activity History page, then you’ll need to customize the Contact Page Layout.  Stay tuned for more!

Advertisements

Tags: , , , ,

4 responses to “Salesforce Call Center tips: Display Call Duration in Minutes”

  1. Jim Mecom says :

    This formula generates a syntax error. What gives?

  2. katy says :

    Hi Jim,
    Thanks for letting me know. Rich let me know that there are two different types of ” symbols, and in programming, you should always use “.
    I’ve corrected it in the post above, and here:

    IF((MOD(CallDurationInSeconds/60,1)*60) > 10,
    TEXT(FLOOR(CallDurationInSeconds/60)) + “:” + TEXT(FLOOR(MOD(CallDurationInSeconds/60,1)*60) ),
    TEXT(FLOOR(CallDurationInSeconds/60)) + “:0” + TEXT(FLOOR(MOD(CallDurationInSeconds/60,1)*60) ))

    Let me know if that works out!

  3. Phillip says :

    For some reason the field has been created correctly but it is read only. Is there any way to undo that limit my staff would like to be able to enter in a date and time manually.

%d bloggers like this: