You need to sign in to do that
Don't have an account?
New case created when including Case Thread ID
I have a VF Email template that is using a custom formula field to grab the thread ID for a case.
An example of my thread ID is: ref:_00D708Lra._50070koi90:ref
The formula that I am using to generate the thread ID is:
I tested by sending a blank email with the thread ID in the subject and the body of the message. No case is opened by SalesForce, which is good as there shouldnt be a new case opened, but the email is never added to the case as a comment. The email just sort of dissapears into nowhere.
Can someone please help me with this?
An example of my thread ID is: ref:_00D708Lra._50070koi90:ref
The formula that I am using to generate the thread ID is:
"ref:_00D"&MID(Id,4,1)&"0"&RIGHT($Organization.Id, 4) &"._"& LEFT(Id,4)&"0"&RIGHT(Id,5) &":ref"
I tested by sending a blank email with the thread ID in the subject and the body of the message. No case is opened by SalesForce, which is good as there shouldnt be a new case opened, but the email is never added to the case as a comment. The email just sort of dissapears into nowhere.
Can someone please help me with this?
How would I be able to see the email coming in? Would I need to write an APEX class that will grab that information upon delivery? If the email isnt being added to the existing case and its not generating a new case, where is it going at this point?
and if that returns results then you are good to continue on with your trigger. Your trigger will be something like:
NOTE: This code has not been tested and may contain typographical or logical errors.
The CreatedBy line when creating the new comment may not work. If it doesn't, just omit it. You may want to adjust / omit the userMap part if you want anyone to be able to create comments on the case. Or adjust it to look at contacts if you want to make sure they have a valid contact record.
You'll want to add additional logic to make sure you don't get stuck in an auto-reply loop, but that's a problem to look into after your initial implentation.
When running select FromAddress, ParentId, Subject, TextBody from EmailMessage where ParentId = '500xxxxx' I get an error returned stating:
INVALID_QUERY_FILTER_OPERATOR:
TextBody from EmailMessage where ParentId = '50070koi90'
^
ERROR at Row:1:Column:73
invalid ID field: 50070koi90
Sorry if I am sounding completely ignorant in all of this but am I running this with 500xxxxx or am I replacing that with that specific part of the thread ID that is being generated?