You need to sign in to do that
Don't have an account?
Khaled Youssef
send email after install
Hello,
i have used the code below to send email after installation of by package , but i received an email from the email of client , how can i receive email from the server smtp ?
global class MyInstallationHandler implements InstallHandler {
global void onInstall(InstallContext argContext) {
Messaging.SingleEmailMessage lEmail = new Messaging.SingleEmailMessage();
lEmail.setSubject('Someone Installed my Package!! yay!');
lEmail.setHtmlBody('Congrats, you have a new Client!');
lEmail.setSaveAsActivity(false);
lEmail.setToAddresses(new List<String> {'test@test.com'});
Messaging.sendEmail(new List<Messaging.Email> {lEmail}, false);
}
}
thanks
i have used the code below to send email after installation of by package , but i received an email from the email of client , how can i receive email from the server smtp ?
global class MyInstallationHandler implements InstallHandler {
global void onInstall(InstallContext argContext) {
Messaging.SingleEmailMessage lEmail = new Messaging.SingleEmailMessage();
lEmail.setSubject('Someone Installed my Package!! yay!');
lEmail.setHtmlBody('Congrats, you have a new Client!');
lEmail.setSaveAsActivity(false);
lEmail.setToAddresses(new List<String> {'test@test.com'});
Messaging.sendEmail(new List<Messaging.Email> {lEmail}, false);
}
}
thanks