How to mark email as unread in outlook folder?

email
outlook
activities

#1

Scenario:

Steps to reproduce:

Current Behavior:

Expected Behavior:

Studio/Robot/Orchestrator Version:

Last stable behavior:
Last stable version:
OS Version:
Others if Relevant: (workflow, logs, .net version, service pack, etc):


#3

If you want you can try using VbScript (as a last resort). This is for custom folder in Root,commented is for Inbox.

Unreading based on Subject (contains) by passing it via Start Process.

image

Const olFolderDeletedItems = 3
Dim Items 
Dim objSubject
Dim Arg
Set Arg = WScript.Arguments
Set objOutlook = CreateObject("Outlook.Application")
Set objNamespace = objOutlook.GetNamespace("MAPI")
//Set objInbox = objNamespace.GetDefaultFolder(olFolderDeletedItems) --> Inbox (check)
Set objInbox = objNamespace.Session.GetDefaultFolder(olFolderDeletedItems).Parent._
     Folders("FolderName")
Set Items = objInbox.Items
Items.Sort "[Received]",True
MarkEmailUnRead(Items)

Sub MarkEmailUnRead(objItems)
	For Each objItem in objItems 
	  objSubject = Arg(0)
	  objsubject = objItem.subject 
	  if Instr(objsubject,objSubject) <> 0 then
	  objItem.UnRead = True
	  objItem.Save
	  Exit For
	  end if 
	 Next
End Sub

Call vbs in UIpath
#4

@praveenmallepu Hey man, have you found out any solution for this?

Thanks
Joshi