Salesforce Admin Hack Series: Account Object

August 28, 2013 Jarrod Kingston

jarrodJust recently I had the privilege of co-hosting a webinar with Michael Farrington of RingLead (Shout out to fellow Appirian Josh Hoskins for hooking us up). This was part of RingLead’s Salesforce Admin Hack Series where they had previously covered hacks for the Lead and Opportunity objects. For this webinar we focused on hacks for the Account object. We had a great turnout having at one point nearly 350 attendees. Let’s go ahead and take a look at the hacks we shared below:

Merge Accounts Button

Shout out to another fellow Appirian, Rhonda Ross, for this hack
Hack Objective: Provide a shortcut to the “Merge Accounts” screen while simultaneously pre-populating the search string.
Button Code: /merge/accmergewizard.jsp?srch={!Account.Name}

Sneaky Related List Action Links

  • Props to Salesforce MVP Ankit Arora for this hack
  • Hack Objective: Edit child records displayed in related lists on the spot with one click.
  • Link to Ankit’s blog post:
  • Hack Setup

-Case Field: HYPERLINK(“/apex/updateStatus?RecId=” & Id & “&AccId=” & AccountId,”Escalate”,”_top”)
-Visualforce Page:
<apex:page >

<apex:includescript value=”/soap/ajax/19.0/connection.js”/>

sforce.connection.sessionId = “{!$Api.Session_ID}”;
var update_Case = new sforce.SObject(“Case”);
var CID = ‘{!$CurrentPage.parameters.RecId}’ ;
update_Case.Id = CID;
update_Case.Status = ‘Escalated’;
var updateRecords = [];
updateRecords.push(update_Case) ;
var result = sforce.connection.update(updateRecords);
window.location.href = ‘/{!$CurrentPage.parameters.AccId}’ ;


Bonus Hack: Edit Links in Reports

  • Hack Objective: Add quick links to edit records from within Salesforce reports.
  • Formula field: HYPERLINK(‘/’ & Id & ‘/e’, ‘edit’, ‘_blank’)

Account Report Link

Hack Objective: Have a custom link on the Account that opens a report filtered on that Account.
Custom Link: /{REPORT ID HERE}?pv0={!Account.Id}

Email Link

  • Thanks to another Salesforce MVP Steve Molis for this hack
  • Hack Objective: Email Account link without copying and posting from browser.
  • Button code: javascript:location.href=’mailto:?SUBJECT={!Account.Name}&BODY=’+escape(location.href);

Record Type Switch in One Click

  • Hack Objective: Change the record type of an Account without having to go through all the manual steps.
  • Button code: {!REQUIRESCRIPT(“/soap/ajax/13.0/connection.js”)}

var acctObj = new sforce.SObject(“Account”);
acctObj.Id = ‘{!Account.Id}’;
acctObj.RecordTypeId = ‘012i0000000jp9j’;
var result = sforce.connection.update([acctObj]);

if (result[0].success==’false’) {
} else {

Previous Article
How to push to multiple remote Git repositories using 1 Eclipse operation (killing 2 birds with 1 stone)
How to push to multiple remote Git repositories using 1 Eclipse operation (killing 2 birds with 1 stone)

By Enda Traynor I recently spent some time trying to figure out this very issue and so thought it would be ...

Next Article
Excerpt from the CloudSpokes Blog: First Look – Aura UI Framework

By Jeff Douglas (@jeffdonthemic) Fun stuff coming out of Salesforce as we ramp up to Dreamforce! I had the ...