You need to sign in to do that
Don't have an account?

Sending Mass Email
Hi all,
Can anyone tell me how to collect the Email Ids from (custom Object Employee ) the list view displaying Employee Email Id List .
I Want send a mail for that selected List of Mail , when i click the send mass email button. it has to collect id of the selected Employee Object and mail to the record.
Can anyone give me a solution for this?
To create List of email try below,
List<Employee__c> lstEmployee = [Select id, Email__c From Employee__c];
Set<String> setEmail = new Set<String>();
if(lstEmployee.size()>0){
for(Employee__c emp:lstEmployee){
setEmail.add(emp.Email__c);
}
}
here your email list is ready. now use below link for code to send emails.
http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_classes_email_outbound.htm
I hope this will helpfull to you.
Thanks for Mass E-mail code.
I have field as subject(s1,s2,s3).. I displayed the one subject (s1)based on query...Now i want to display S1,S2,S3 in same query..using Where clause..It s possible? send any Sample Codes
Ex:
Select subid from subject where s1