Mark Emails As Unread after doing some comparison on Excel

Hello, Can anyone help me on the below query?

See my Project flow :

  1. Get Outlook Mail Activity: (read all unread emails)
  2. Want to check something on Excel File (Compare Excel data with Email)
    3. IF excel comparison not match then I want to move that email to One Specific “XYZ” Folder and need to unread that email.

How should I achieve this ? My question is at Point 3.

Thanks in Advanced.

There is a “Move Outlook Mail Message” activity as well as a “Mark Outlook Mail As Read/Unread” activity. Have you attempted either of these?

Hi

Fine let’s go one by one

  1. This can be achieved by selecting ONLY UNREAD MESSAGES property along get outlook mail activity
  • OnlyUnreadMessages - Specifies whether to retrieve only unread messages. By default, this check box is selected.
  1. And you can move to a folder we want with this activity

And mark as unread again with this

Cheers @pari_patel

Hello @Palaniyappan ,

Thanks for your reply with explanation but still, which activity should I use in Step 3?

@pari_patel I see your problem: Move Outlook Mail Message does not return an MailMessage object corresponding to the moved email so you cannot use it as input parameter for Mark Outlook Mail As Read/Unread. I will add this as enhancement for a next release of Mail package.

As a workaround, you can store the message ids of the matching emails using mailmessageobject.Headers("Message-ID"). Then call again Get Outlook Mail Messages activity passing the list of message ids to FilterByMessageIds parameter and also check MarkAsRead option.

Another option: you can also mark the email as unread before moving it.

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.