But headers throwing error
As I said all the emails might not have headers. SO first you need to do a count of keys to check if the header is present only then you can check for required keys.
item.Header.keys.count will give the count
Let me know why you want to use header data may be that might help to point you in right direction
My bad it is item.Headers.Keys.Count instead of Header
I want to exrtract the sent date from sent items so i use item.Headers(“date”)
But it is not showing results so what to do in microsoft 365 get mails
Please use item.LastModifiedDateTime which will give you the required date and time
Im assigning values to get mail so when i put item.LastModifiedDateTime it says compiling error
are you using office 365 get mail? because I see the mailmessage type is different. Can you check in the type argument of for loop and change the type argument appropriately to office365mailmessage
Please don’t use headers. use item.LastModifiedDateTime for the date that you need
Use item.LastModifiedDateTime.ToString() as you are trying to assign the value to string
sure will do but i have typed something but due to internet issue couldnt convey my whole message
Actually i need one help like im trying this automations for more than 15 days so could you please help me on this?
how to retrieve Microsoft 365 get mails like whether i have replied for that mails or not from sent items, so may i know how to do that?
good to know .Happy Automation. Please mark the solution so that it helps others
So …you want to know if a message is replied or not… there is no direct way but you can try this… from get mails once you get your inbox …and getting the mail you can get the unique id of the mail and then use get mail from sent items and then match the id for this your in-reply-to in header will help to match.thats not straight but give it a try
Happy birthday @Anil_G
Actually the headers is not working…previously it was working in get imap but
item.headers.item(“In-reply-to”) is not working in either in o365 and exchange get mails
Thank you so much … that will work only for sent items…so try that header in sent…first check what keys you are getting. Wven i will check it but as of now little away from laptop…will give you update as well
hope you had a great day @Anil_G … ok thank you
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.