function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
parkerAPTparkerAPT 

How to add custom buttons to related Lists? (Specifically Task/Activities)

Does VF support adding custom buttons to related lists?

This post indicates that it's not possible on the Attachment related list.
http://community.salesforce.com/sforce/board/message?board.id=general_development&message.id=23349

However, I'm wondering if you can add custom buttons to other related like for a Contact's Activity History?

Thanks
Parker
beener3beener3
Do this in the page in which the related list is located.

If for example the list is in a Contact's detail page, do it in the Setup-> Contacts -> Page Layout.
Edit the layout. double click on the related list.

Hope that helps.
parkerAPTparkerAPT

beener3 wrote:
Do this in the page in which the related list is located.

If for example the list is in a Contact's detail page, do it in the Setup-> Contacts -> Page Layout.
Edit the layout. double click on the related list.

Hope that helps.



In that section, from what I can tell you can only remove standard buttons but not Add your own custom buttons to the related lists. I can see how you would add a button for the Detail view, but not the related list. Any I looking in the wrong spot?

[[EDIT]]
Whoops, I didn't have any custom buttons to add, so none were showing up.

It also looks like I can only use sControls and not a custom Apex Controller action, that's unfortunate.

Message Edited by parkerAPT on 12-30-2008 04:02 PM
dchasmandchasman
It also looks like I can only use sControls and not a custom Apex Controller action, that's unfortunate.

Not exactly - sure your VF page must use the standardController (note that standardController="blah" can refer to standard and custom objects - that confuses a lot of people at first) but you can mix in as many custom extensions as you need. There is very little difference between a controller and a controller extension w.r.t capabilities. The standard controller requirement is pretty well outlined in the docs but the main idea is we're trying to insure that the basic requirements for an override/custom button/etc target will be met by your page (e.g. the id query param will be respected and correctly handled).


Message Edited by dchasman on 12-30-2008 10:30 PM