Setting From Address in Single Email Message in Salesforce

In Salesforce, you can set the “From” address in a SingleEmailMessage by using the setOrgWideEmailAddressId method. Here’s an example of how you can set the “From” address: Make sure to replace [OrgWideEmailAddressId] with the actual Organization-Wide Email Address ID that you want to use as the “From” address. The Organization-Wide Email Address must be previously …

Setting From Address in Single Email Message in Salesforce Read More »

Vote Article as Guest/Unauthenticated User in Salesforce Community

INTRODUCTION How can We enable article voting for the guest users without prompting them to login. Salesforce lets guest users vote their own article without logging in. SOLUTION To allow guest users to like or dislike articles in Salesforce, you can follow these steps: Here’s an example of how the code: LWC: LWC JS Controller …

Vote Article as Guest/Unauthenticated User in Salesforce Community Read More »

Not Able to upload File under task in Salesforce Mobile App

You can not upload file under Task using related list in Salesforce Mobile App. This is Salesforce feature limitation in mobile app. We can add File button on task layout that will give option to upload file on Task level. And related uploaded files will appear in related list.

Top five problem using delegated approval in Salesforce

What is delegated approval and when it is enabled? When your team’s member goes on out of office, we can choose a user to receive his approval requests over a predefined time period. Delegated approvers are helpful when the original approver can’t respond to approvals, such as during a vacation. https://help.salesforce.com/s/articleView?id=sf.cpq_aa_delegate_approvers_task.htm&language=en_US&type=5 Known Challenges Before enabling …

Top five problem using delegated approval in Salesforce Read More »

INVALID_ID_FIELD, WhatId is not available for sending emails to UserIds

Introduction This error is thrown while sending email using apex if you are setting User Id in target recipient: setTargetObjectId(usr.Id) and also specifying target record id as: setWhatId(opp.Id). As per Salesforce documentation if you are passing record id in WhatId then you can only pass Contact Id in setTargetObjectId. Here is Salesforce article: https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_classes_email_outbound_single.htm Workaround

Recalculate Formula Fields Dynamically (without save)

From the Documentation: Recalculates all formula fields on an sObject, and sets updated field values. Rather than inserting or updating objects each time you want to test changes to your formula logic, call this method and inspect your new field values. Then make further logic changes as needed. See https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_methods_system_sobject.htm Note that this method doesn’t recalculate …

Recalculate Formula Fields Dynamically (without save) Read More »