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
paulmagpaulmag 

referencing standard fields in a custom button

Hi there guys looking for some help with creating custom buttons.

I am trying to pre-populate a sales case when a user hits my new button but am struggling to reference the Close Date and the Stage. when I am referencing a custom field i can see the salesforce ID but this is missing from the standard fields. Also is there anything that needs done when trying to populate a picklist?

 

Thanks in advance

 

Paul

SurekaSureka

Hi,

 

For the Close Date Feild , Id is "CloseDate" and  id for the stage is "StageName".

 

To populate a picklist feild, concatenate the custom button url with "00N80000004kxqP=abc" where "00N80000004kxqP" is the id of the picklist feild and "abc" is the value in the picklist feild.

 

Hope this helps.

 

Thanks

paulmagpaulmag

thanks for the response but I cant make it work for me i have put it

 

&stagename=pledge (and variantions of this) and it saves but doesnt populate the picklist. Do I need the cruly braces as well? {!opportunity.stagename__c=Pledge}

 

Thanks for helping

 

Paul

SurekaSureka

Hi,

 

You can use "opp11" instead of "StageName" . ie. opp11=Prospecting

 

Refer to this link for more info : Link

 

Thanks