Email services are automated processes that use Apex classes to process the contents, headers, and attachments of inbound email.

learn more… | top users | synonyms

0
votes
1answer
40 views

How to get Email Template executed body

I am working on sending email by using 3rd party application like Amazon SES When i query for perticular email template i am getting body whaever the email templated had like Email Template body ...
1
vote
1answer
19 views

How can I strip additional email address from Messaging.InboundEmail array

I am using an email service to update opportunities in my salesforce instance, what my handler does it lift any email addresses in the CC field and then does a search for the contact via SOQL, once ...
1
vote
2answers
32 views

creating an email based on another record

I want to be able to share the contents of a field from a particular record with an email recipient. Rather than going to the record and copying the field value, I would like to be able go the the ...
1
vote
1answer
48 views

Approval by email using custom salesforce email service

I am trying to implement approval or rejection by email functionality. But I can not use salesforce standard 'Enable Email Approval Response' functionality as approval process is assigned to queue ...
0
votes
1answer
16 views

attach received mail in Contacts attachment

We have status field on contact. Once status becomes active , we have to create a Partner user and send term and condition mail to Contact email address. Once the Contact replied "accepted", then he ...
0
votes
0answers
26 views

Messaging.MassEmailMessage class doesn't work when we set a list of case ids as whatids. It works fine if we don't set whatids

Please help me fix my issue with Messaging.MassEmailMessage class. It doesn't work when I set a list of contactIds as my targetObjectIds and set a list of case ids as whatids. It works fine if i don't ...
1
vote
3answers
53 views

How do I correctly add a helper method to my Apex Class?

I am attempting to set up an email-to-lead email service. Our non-profit receives leads in the content of emails that are sent, and I am trying to write an apex class that correctly parses the ...
1
vote
2answers
66 views

Differences between email to case and on demand email to case

I haven't worked on configuring email to case before and there are basically two options. (Email to case and On demand email to case) I found a few links listing the differences in terms of ...
0
votes
2answers
25 views

Send Email with Case Email Template

I would like to send an email template ,with merge fields from case, even to a fixed address'test@email.com'. Template: Hi, this is case {!Case.CaseNumber}. Code: public void ...
4
votes
3answers
257 views

Making regex case-insensitive

I have created some lines of code for an email handler that will scrape my emails for a particular string (STA0123). Code: // Find STA No. (in email body) Opportunity Opp = [SELECT id, STA_No__c ...
0
votes
1answer
35 views

Conversion Error setting value '01590000004fxbiAAA' for '#{documentId}'

Hi everyone i want to send multiple attachment through mail. So i created a checkbox to select the required document and send them but it is throwing this error "Conversion Error setting value ...
0
votes
0answers
22 views

How does the “Internal Comment” field behaves in Email to Case Premium app

Can any one help me out .I shall appreciate your help. How does the "internal comment" field works in Email to case premium app? a)When we create a case manually the internal comment field gets ...
1
vote
1answer
126 views

Inbound email missing attachment?

I have a requirement to save attachment received from email in Salesforce object using Email To Salesforce. I tried using the below code but attachment are not getting saved, when I checked using the ...
3
votes
2answers
33 views

What is the best way to populate data from external users

My SF instance needs to get data and approvals from a lot of external users outside of the organisation. I would like to know what is the best solution to get data from these users without giving them ...
0
votes
1answer
80 views

Email File Attachment type

I am trying to send an attachemnet in an email. I am able to do so the problem that i am having is that I am not able to get the original name and content type of the attachment. Is there any way of ...
1
vote
1answer
150 views

How to override the FROM Email in Messaging.SingleEmailMessage

How to override the from email address in the email.But in my code throw an exception.How to set the Organization-Wide email addresses.When I comment the code "setOrgWideEmailAddressId(owe.Id);"it ...
-1
votes
1answer
16 views

Email Service: Filtering quoted text (response history) from message body before saving

I have an email service which saves message body to linked Opportunity in the Notes. Although this works, this will save ALL the content from the email including all previous correspondances if they ...
0
votes
3answers
52 views

Email Service: Attempt to de-reference a null object

I have created a Email service which saves attachments into opportunites, when sending emails an error message is returned back to the mailbox stating that it has failed processing because Attempt to ...
0
votes
1answer
52 views

Email attachment not received in EmailService handler

I have an issue with processing inbound emails sent from MS Outlook. To put it simple no attachments are received in the class (nor text nor binary). Email definitely has attachments since i cc-ed the ...
1
vote
1answer
57 views

How to add the logo in email body

How to add the logo in HTML email body. I have use an apex class that send an notifications to customers.The below code is send an emails to customers **but in email body the image/logo is not ...
2
votes
0answers
72 views

Dynamic Email Template Body

I have a requirement where I need to send the email template and also allow the use to change it and then send the content. I am able to send email and attach a VF template dynamically. But I am not ...
1
vote
1answer
98 views

Attach dynamically generated visual force PDF to a visual force template

I have a requirement where I need to attach an email template to a dynamically generated VF PDF. Though I am able to send the template. But I am not able to send the attachment. Please suggest how can ...
1
vote
1answer
38 views

Sending e-mails to contacts

My org have a lot of contacts - around 2000. All of these contacts have e-mail address. I need to send an e-mail to each of them. An admin will enter a body (on a VF page) and click "send e-mails" ...
0
votes
0answers
26 views

Routing Emails to multiple queues based on context?

I'm trying to figure out a way to parse emails that come in via email-to-case and assign them to the correct queues. Where this gets interesting is that although we can match the contact and account ...
0
votes
0answers
10 views

How to send the attachment in to the choosing option Email template email author?

I have create the visualforce page to Three buttons and i will written code to attach the attachment into the custom Notes and Attachments in the related list.but if i'm clicking the one button it has ...
0
votes
0answers
25 views

Grab Date via Apex from Inbound Email

When using Salesforce for Outlook, we'd like to somehow pass the date/time the original email was sent, so we can track exactly how long a case / response took. I know there are many items that can ...
2
votes
1answer
62 views

How to unzip a zipfile attachment in apex and process each file in the zip attachment

I am trying to unzip a zip file attachment. but, unable to unzip the attachment and process all the internal files in the zip file. I want to do this using an email handler class.
0
votes
0answers
12 views

How to stop creating the email signature graphics as attachments but still have the remaining attachments created

How to stop creating the email signature graphics as attachments but still have the remaining attachments created and associated to the related case when using Apex email service?
2
votes
1answer
42 views

Sending Addional Information through Inbound email Service?

We Want to send Additional Information such as Contact name, phone number etc through the email headers. Is it possible to do so and How? Since it's only name value pair is there any mechanism ...
0
votes
3answers
64 views

Send Email Button

I am trying to create a custom send email button on a custom object called Disease__c. I have patients linked to the disease, where disease is the Master in the master-detail relationship. ...
-2
votes
1answer
65 views

Test class passed, but main class only 44%

Good Morning Salesforce Stackexchange I have the following test class called “DeactivateUsers_Test” which has passed however main class “DeactivateUsers” is only getting code coverage of 44% ...
0
votes
1answer
73 views

Test class coverage varies betw Sandbox/PROD for trigger that sends an email

I am having difficulty when trying to create the test class for my trigger: trigger Email_Pesquisa_Mercado_account on Account (after update) { Map<Id,Account> accountMap = new ...
0
votes
1answer
35 views

Trying to implement a list to select Records, and email attachments, could use some pointers!

I recently just started working with Salesforce and Apex/VisualForce and was attempting to implement a page to email out the attachments of a Service Contract, however I seem to be stumbling with the ...
1
vote
1answer
24 views

Monitor email service with data feed: email report

I am surprised I do not find find any examples of best practices on this matter. So, I have feeling maybe I am doing something wrong. We have email service which is receiving emails with CSV file ...
2
votes
0answers
238 views

Email To Case - Duplicate Cases

Have an interesting problem with Email To Case setup, scenario is User A sends an email to a support mailer and copys User B on it. Auto response would go to User A. If User B picks up the first email ...
0
votes
1answer
132 views

Undeliverable email to email service

I am getting this error when writing email to my email service in my developer environment - using the email address I created the environment: This message was created automatically by the mail ...
2
votes
0answers
89 views

Custom InboundEmail handler - check if message is an automatic reply

I've implemented a custom inbound email handler for some departments using email-to-case, and we would need to avoid autoreply messages or automatic generated messages to create cases or trigger other ...
0
votes
0answers
420 views

How to insert Activity History record after sending an email

I cannot create a new Activity History record when using message.setSaveAsActivity(true); so i added mail.setTargetObjectId(con.id); its working fine. but actual issue is when i am sending mail ...
1
vote
2answers
248 views

Create and select attachments and add them to an email template?

Here's the setup of my problem, and i'm not sure how to get started. initial screen -> my user is on a VF page and makes some HTML selections. Also, they select a number of notes and attachments. ...
3
votes
1answer
97 views

PDF file name issue in apex Send Mail method

I want to add date to a PDF file name. I am sending an email from apex and attaching one PDF file with it. Now I want to set string with dynamic date with it. E.g.... date fromdate = ...
1
vote
1answer
182 views

Email Service Generate Email Address

Here i was made one Inbound Email Service..For that i made one Apex Class,here the code of the class... global class EmailDemoReceive implements Messaging.InboundEmailHandler { global ...
0
votes
1answer
418 views

how to fetch a notes and attachment of custom object and i want to send the notes title and body through of contact in accounts

i have already done some codes check the codes below and tel me what's wrong in this public PageReference send() { List<Contact> accounts=[SELECT Email,id FROM Contact WHERE AccountId ...
2
votes
0answers
98 views

Email Services + How to handle undelivered or bounce emails

This might be a known issue. But i could not find enough info to resolve the issue. We are using Email Service's email address as a From address to send emails to consumers. If consumer's email ...
1
vote
0answers
165 views

send email notification to a profile when lead is created

I'm trying to send an email to user a & b, when ever a on lead (created & updated) & the appointment info is available. Usually, i can do this by writing an workflow, but unfortunately, i ...
0
votes
1answer
78 views

Update custom object from Email service attachment

The use case is sending an attachment(csv) to my email service ; in the email service i will parse the csv ; each line of the csv will have values like key1,key2,value1 I have to query the custom ...
3
votes
2answers
92 views

Work out remaining singlemailmessage capacity in test

I have an Apex class that does some complicated decisions surrounding whether to send an e-mail to a user or not, including the fundamental "can we send any more e-mails today" check from Salesforce: ...
0
votes
1answer
55 views

Mass email a form to be filled out

I'm trying to capture quotes from vendors into our org. We have EE and we do not have Sites.com. Scenario: A Contact is marked Vendor Source. Purchase Request object and line items from related ...
0
votes
0answers
31 views

How to write email service class for the following xml?

VC 1.3 Response xml: <?xml version="1.0" encoding="UTF-8"?> <ValidateConfigResult> <Configuration> <ConfigId>CE05502807</ConfigId> <Status>false</Status> ...
0
votes
3answers
835 views

How to get parent object field values in a trigger

I have created a trigger that send an email when some conditions are met in a task object. It is working fine but I need to get some field values from the parent object (an opportunity) in order to ...
3
votes
1answer
635 views

Test class for sending email with Attachment

I need a test class for sending a email public blob body; public PageReference pdfmethod(){ try { // to get mail id Opportunity_Potential__c opp= [Select ...