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
DharshniDharshni 

Getting Email Signature and Settings through code

I have a page which sends emails. I have set  'Would you like to automatically BCC emails to your return address?'  to 'YES'  under 'Personal Setup->Email->My Email Settings'. But the emails sent through apex code are not sent as BCC to my return address?

 

Is there any method to access this setting of an user through apex code? 


Also would like to know methods to get the Email Signature field of user through code. 

 

Thanks. 

 

 

Anup JadhavAnup Jadhav

If the email is sent by the apex code, then you have control over how the email is sent, not the platform. The setting that you have checked controls the emails sent by the platform, but a visualforce page backed by a controller sends an email that you've created in the apex code, then you set the params for the Email.

 

- Anup

DharshniDharshni

Thanks Anup.

 

I wonder if there is any way to access this setting through Apex code? I understand its only meant for platform emails. But is it possible to utilize this feature for emails sent through Apex?

 

Thanks again.

Anup JadhavAnup Jadhav

I am afraid there is no such setting.

 

Thanks,

Anup