- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-24-2015 05:05 AM
Hi Members,
I have an inbound email action that simply captures the response (replies only) and whatever comes in the email copy it to the ticket's comments. But if that email becomes a chain, multiple replies, the whole chain gets updated each time. That can be avoided if there is a way to capture the latest response in the incoming email.
Has anyone done this?? or any ideas??
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-24-2015 05:15 AM
Never tried this but i think the approach for this would be to take only the content from the email where "From" starts with senders name. Found similar query on stack overflow.Below is the link:
javamail - Reading only the latest replied content using java mail multipart MIME - Stack Overflow
http://stackoverflow.com/questions/16984235/parsing-reply-email-to-take-only-the-latest-part
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-24-2015 05:15 AM
Never tried this but i think the approach for this would be to take only the content from the email where "From" starts with senders name. Found similar query on stack overflow.Below is the link:
javamail - Reading only the latest replied content using java mail multipart MIME - Stack Overflow
http://stackoverflow.com/questions/16984235/parsing-reply-email-to-take-only-the-latest-part
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-24-2015 05:36 AM
Thanks Sachin
Here is the final solution
var messageContent = email.body_text;
if (messageContent.indexOf("From")!=-1)
{
messageContent = messageContent.substring(0, messageContent.indexOf("From")).trim();
}
else
{
messageContent = messageContent.trim();
}
// now messageContent contains the latest reply only....
I have tested incoming mails from Microsoft Ourlook....ill will check from some other sources also and will post in case of any issues....
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-24-2015 05:41 AM
Welcome. Lotus notes also have the similar mail format as that of Outlook so it will for lotus notes as well.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-24-2015 05:44 AM
That was my only worry as i don't have lotus notes....web mails and all i will check but i am positive that it will work