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
Kumar GKumar G 

Custom List button is showing in Lightning Experience.

I have a related list button it is showing in classic but when I have switched to Lightinging it is not visible in the related list.

Plz find the button code in code sample and suggest me how to modify this button code for Lightning.
{!REQUIRESCRIPT("/soap/ajax/22.0/connection.js")} 
{!REQUIRESCRIPT("/soap/ajax/22.0/apex.js")}; 
var result = sforce.apex.execute("MarketingProgramDetailWebservice", "getBaseURL", 
{ 
recordTypeName: '{!Marketing_Programs__c.RecordType}' 
}); 
if(result == '') { 
window.parent.location.href = '{!$Action.MarketTool__c.New}'; 
} 
else { 
window.parent.location.href = result + '&CF00N80000004z6fM={!JSENCODE(Marketing_Programs__c.Name)}&CF00N80000004z6fM_lkid={!Marketing_Programs__c.Id}&retURL=%2F{!Marketing_Programs__c.Id}&saveURL=%2F{!Marketing_Programs__c.Id}';

Thanks..
NagendraNagendra (Salesforce Developers) 
Hi Kumar,

Sorry for this issue you are encountering.

Custom List Buttons are not showing up in Open Activities/Activity History Related Lists in Lightning Experience,Activities , Lightning

Last updated 13 days ago ·Reference W-4542613 ·Reported By 9 users
SCHEDULED - SUMMER '18

Summary:

Custom List Buttons are not showing up in Open Activities/Activity History Related Lists in Lightning Experience but they show in Classic

Repro

1. Switch to Classic first. 
2. Set up-> task buttons,links and actions-> create a new custom button. 
3. Go to case page layout, -> related list-> open activities -> edit-> button, and add "custom button " to selected buttons -> save 
4. Go to case, you could see custom button under open activities. 
5. Switch to lightning, go to case, you only see "new event" and "new task" button.

Workaround:

None at the moment.

Hope this helps.

Kindly mark this as solved if my reply was helpful.

Thanks,
Nagendra