web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Update Service Activity Status based on Email

(0) ShareShare
ReportReport
Posted on by

I am looking for a way for my technicians in the field to update the status of their Service Activities when they arrive on site. I initially wanted to use the phone app however this is not possible it seems. When a technician is assigned a service activity they will be sent an email with the job information. Is there any way for them to reply to the email and have the status of the Service Activity updated to in Progress? If anyone has any other ideas that would be great. I know they have the ability to do it through their laptops but trying to avoid them having to pull that out when they arrive on site.

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Brad Sprigg Profile Picture
    985 on at

    If the reply email is automatically synced to CRM via Server-side Sync or the Email Router, you might be able to do this via a plugin. First thing you will need to do is find the original email they are replying to so you can check the regarding field to find out which Service Activity they are referring to. One method I have used before is to check the conversationindex field of the newly created Email record. I then used the following code to find the original email.

    Entity originalEmail = FindOriginalEmail(localContext, conversationIndex.Substring(0, 44));
    private Entity FindOriginalEmail(LocalPluginContext localContext, string conversationIndex)
            {
                var orgService = localContext.OrganizationService;
    
                QueryExpression query = new QueryExpression();
                query.ColumnSet.AddColumns("activityid", "trackingtoken");
                query.EntityName = "email";
                query.Criteria.AddCondition("conversationindex", ConditionOperator.Equal, conversationIndex);
    
                EntityCollection results = orgService.RetrieveMultiple(query);
                if (results.Entities.Count == 0)
                {
                    return null;
                }
                else
                {
                    localContext.Trace(String.Format("Number of emails found - {0}", results.Entities.Count));
                    Entity returnValue = results.Entities[0];
    
                    localContext.Trace("Exiting FindOriginalEmail");
                    return returnValue;
                }
            }

    From there you should be able to use the Regarding field to identify and modify the Service Activity.

  • Suggested answer
    Community Member Profile Picture
    on at

    Was looking for an out of the box solution but I guess there is none at this time. Thanks!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans