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
valmeidavalmeida 

Setting the "Related To" picklist value via a custom button.

Hello:

I was referred here from the Formulas & Validation Rules Board.

I was told this approach is not officially supported by salesforce (even though they present this technique in various forums), but I would like to proceed. I have a custom object with a custom button that creates a child Task and presets the values on several Task fields.  I'm having trouble defaulting one field - the Related To picklist.  I want the parent object name in the picklist to default, but I can't seem to do it. Using Firebug, I determined that the Related To picklist field is tsk3_mlktp, but no matter what I try, I can't get that field to default to my custom object name within that picklist.  I've tried the object name in double-quotes, as well as the object ID.  If I use the object ID, It does populate the actual object ID in the Related To field, but what I need is the value/name of that object.  

Any suggestions? Thanks. 

 

Original posting: http://boards.developerforce.com/t5/Formulas-Validation-Rules/Setting-the-Related-To-picklist-value-via-a-custom-button/td-p/281317