Creating a Custom Log a Call Button - Answers - Salesforce Trailblazer Community
Trailblazer Community
Ask Search:
Karin PettyKarin Petty 

Creating a Custom Log a Call Button

I want to create a custom button that when you click on it opens the Log a Call window. However, I cannot figure out how to get the code to work properly. This is what I have done so far:

{!LINKTO('Log A Call', '$Action.Activity.LogCall', '$ObjectType.ActivityHistory')}

Am I doing this correctly?
James GarfieldJames Garfield
Hey Karin,

All depends on how you want this link to display. I am a huge fan of creating a button (similar to the log a call button). What you need to do is create a URL that will pass through the information that you are looking for. 

Send me an email to james.c.garfield@gmail.com 
We can set up a screen share and I can walk you through making a completely functional custom button that can prepopulate pretty much anything!

Best of luck!
Johan YuJohan Yu
try this url, change xxx to your salesforce instance

https://xxx.salesforce.com/00T/e?title=ABC&what_id={Account.Id}&followup=1&tsk5=Call&retURL=%2F{Account.Id}


James GarfieldJames Garfield
Johan,

Using whatid={!Lead.Name} wouldn't work, you need to specify what the field is equal to...

For instance for a lead you have to use:
&tsk2=00Q for leads

Just an fyi!

Best,
Daniel HoechstDaniel Hoechst
@Johan - best practices when creating a url that points to Salesforce is to leave off the https://xxx.salesforce.com part of the link. If you just use /00T/e, it will be smart enough to us the right instance. This is really helpful when going from Sandbox to Production or if Salesforce ever decides to move you to another instance.
Rakesh GuptaRakesh Gupta
Hi Karin,

JohanJohan + 1 Pass Who_id also John code is correct....If you still getting problem please let me know...at rakeshistom@gmail.com... a week ago i crated same button of my last assignment...


Please mark this as a best answer if your query is resolved, so it will help others in future.

Regards,
Rakesh Gupta
Johan YuJohan Yu
@Daniel, you are right on eliminate https://xxx.salesforce.com

@James, yes, not to combine what_id and who_id, it depend on what object it should call from.

@Karin, you can just simpley use to point to URL '
/00T/e' for general usage.