How to Get (item.headers(“date”)) to type ‘Date’ is not valid

Hi,

i need to get e-mail 3 Times
1.Round 1 : From (-1 Backdate) 00.00 AM - 09.00 AM “start Bot 09.00”
2.Round 1 : From 09.01 AM- 14.00 PM “start Bot 14.00”
3.Round 1 : From 14.01 PM- 18.00 PM “start Bot 18.00”

This Code But ‘Date’ is not valid


Ps.Same email subject but different time in order not to duplicate bots.

Please Help
Thank You

i saw that you wrote headers(“DateReceived”) instead of headers(“Date”) ?

1 Like

DateReceived : when Received e-mail

in the get mail message activity change filter to this
"([Received] >= '" + DateTime.Today.AddDays(-1).ToString("d") + " 00:00AM' AND [Received] <= '"+ DateTime.Today.AddDays(-1).ToString("d") + " 09:00AM') OR ([Received] >= '" + DateTime.Today.ToString("d") + " 09:01AM' AND [Received] <= '"+ DateTime.Today.ToString("d") + " 02:00PM') OR ([Received] >= '" + DateTime.Today.ToString("d") + " 02:01PM' AND [Received] <= '"+ DateTime.Today.ToString("d") + " 06:00PM')"


then delete this assign

1 Like

็Hi,jack.chan

i Try Your Code :output is Incorrect
i want to get mail to day is 22/04/2022 7.55 AM

But out put This the below “Yesterday” 15:37 PM"

can you remove the if and just use write line to print subject?
image

1 Like

Thank You Very much.

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