Count received mails of yesterday

  • Thread starter Thread starter Martin Los
  • Start date Start date
M

Martin Los

I have a macro counting:
1. nº answered mails yesterday
2. nº pending mails from yesterday

Then I concluded that the nº of received mails must have
been the sum of 1+2 (or: received mails yesterday =
answered mails yesterday + pending mails , error!!!!).

The error consist in the fact that the answered mails
yesterday could have been received before the day of
yesterday!!!

So how can I correct this?
I already have the macro checking the send mail folder and
checking for "send date = yesterday". What I miss is a
check for "received date = yesterday" as well?

Any tips are greatly welcomed! TIA

Martin
 
So how can I correct this?
I already have the macro checking the send mail folder and
checking for "send date = yesterday". What I miss is a
check for "received date = yesterday" as well?

You can use MAPI to get to the email and then use the ReceivedTime
method on the mail item.


Regards

Lars Roland.
 
Dear Lars:

Since I am not used to MAPI programming, do you have any
example?

TIA

Martin
 
What about using MailItem.ReceivedTime from the Outlook object model?

--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
Go with Sue's example, it is much easier - heh i did not think of that
one, sorry.

Regards.

Lars Roland
 
I am afraid the task is a bit more complex. Let me try and
explain. I give an easy example:

In the olFolderSentMail I have 20 messages I sent
yesterday; 5 messages are "original" messages (= "New" I
created and sent them) and 15 are responses (= "Reply" to
an answer to a received message in my Inbox).

Of those 15 responses I wrote, 12 emails were originally
received the same day (=yesterday), but 3 were received
before yesterday!

Checking messages in olFolderSentMail for ReceivedTime
will give me the time the olFolderSentMail received the
answered mail. BUT IT WILL NOT TELL ME WHEN I RECEIVED THE
ORIGINAL MESSAGE I RESPONDED TO!
To check for the date received I guess I should look into
the body of the responded message (or does a property
exist that tells me the received date of a responded
message?).

Any ideas? TIA

Martin
 
A sent message that is a reply contains no property related to the arrival
time of the original message that was replied to, but you are correct that
the body of the message would contain that date, assuming you don't delete
Outlook's automatic reply header.

--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
How to accesing the body of the message I can read in your
book I recently bought Sue.

2 months ago Dmitry Streblechenko said that with
Redemption, Extended MAPI or CDO 1.21 it is posible to:

1. read PR_CONVERSATION_INDEX property and find an e-mail
in the Sent Items folder with the same value of
PR_CONVERSATION_INDEX property plus 5 bytes.

2. read PR_MESSAGE_DELIVERY_TIME and
PR_LAST_VERB_EXECUTION_TIME (0x10820040), which last
property is what Outlook uses when it displays "You
replied on..." or "You forwarded this message on...".

How does these extended MAPI properties help me find an
answer to my question?
I need tipos how to interpret these properties!

TIA

MArtin
-----Original Message-----
A sent message that is a reply contains no property related to the arrival
time of the original message that was replied to, but you are correct that
the body of the message would contain that date, assuming you don't delete
Outlook's automatic reply header.

--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers



I am afraid the task is a bit more complex. Let me try and
explain. I give an easy example:

In the olFolderSentMail I have 20 messages I sent
yesterday; 5 messages are "original" messages (= "New" I
created and sent them) and 15 are responses (= "Reply" to
an answer to a received message in my Inbox).

Of those 15 responses I wrote, 12 emails were originally
received the same day (=yesterday), but 3 were received
before yesterday!

Checking messages in olFolderSentMail for ReceivedTime
will give me the time the olFolderSentMail received the
answered mail. BUT IT WILL NOT TELL ME WHEN I RECEIVED THE
ORIGINAL MESSAGE I RESPONDED TO!
To check for the date received I guess I should look into
the body of the responded message (or does a property
exist that tells me the received date of a responded
message?).

Any ideas? TIA

Martin
-----Original Message-----
Go with Sue's example, it is much easier - heh i did
not
think of that
one, sorry.

Regards.

Lars Roland


On Tue, 10 Aug 2004, Sue Mosher [MVP-Outlook] wrote:

What about using MailItem.ReceivedTime from the
Outlook
object model?
Dear Lars:

Since I am not used to MAPI programming, do you
have
any
example?

TIA

Martin
-----Original Message-----
On Tue, 10 Aug 2004, Martin Los wrote:

So how can I correct this?
I already have the macro checking the send mail folder
and
checking for "send date = yesterday". What I
miss
is a
check for "received date = yesterday" as well?


You can use MAPI to get to the email and then use the
ReceivedTime
method on the mail item.


.
 
You will need to read these properies from the messages in both the Inbox
and Sent Item folders to to find out how the messages are related.
Did you look at the messages with MdbView or OutlookSpy (click IMessage) to
ply with these properties?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


Martin Los said:
How to accesing the body of the message I can read in your
book I recently bought Sue.

2 months ago Dmitry Streblechenko said that with
Redemption, Extended MAPI or CDO 1.21 it is posible to:

1. read PR_CONVERSATION_INDEX property and find an e-mail
in the Sent Items folder with the same value of
PR_CONVERSATION_INDEX property plus 5 bytes.

2. read PR_MESSAGE_DELIVERY_TIME and
PR_LAST_VERB_EXECUTION_TIME (0x10820040), which last
property is what Outlook uses when it displays "You
replied on..." or "You forwarded this message on...".

How does these extended MAPI properties help me find an
answer to my question?
I need tipos how to interpret these properties!

TIA

MArtin
-----Original Message-----
A sent message that is a reply contains no property related to the arrival
time of the original message that was replied to, but you are correct that
the body of the message would contain that date, assuming you don't delete
Outlook's automatic reply header.

--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers



I am afraid the task is a bit more complex. Let me try and
explain. I give an easy example:

In the olFolderSentMail I have 20 messages I sent
yesterday; 5 messages are "original" messages (= "New" I
created and sent them) and 15 are responses (= "Reply" to
an answer to a received message in my Inbox).

Of those 15 responses I wrote, 12 emails were originally
received the same day (=yesterday), but 3 were received
before yesterday!

Checking messages in olFolderSentMail for ReceivedTime
will give me the time the olFolderSentMail received the
answered mail. BUT IT WILL NOT TELL ME WHEN I RECEIVED THE
ORIGINAL MESSAGE I RESPONDED TO!
To check for the date received I guess I should look into
the body of the responded message (or does a property
exist that tells me the received date of a responded
message?).

Any ideas? TIA

Martin
-----Original Message-----
Go with Sue's example, it is much easier - heh i did not
think of that
one, sorry.

Regards.

Lars Roland


On Tue, 10 Aug 2004, Sue Mosher [MVP-Outlook] wrote:

What about using MailItem.ReceivedTime from the Outlook
object model?

"Martin Los" <[email protected]>
wrote in message
Dear Lars:

Since I am not used to MAPI programming, do you have
any
example?

TIA

Martin
-----Original Message-----
On Tue, 10 Aug 2004, Martin Los wrote:

So how can I correct this?
I already have the macro checking the send mail
folder
and
checking for "send date = yesterday". What I miss
is a
check for "received date = yesterday" as well?


You can use MAPI to get to the email and then use the
ReceivedTime
method on the mail item.


.
 
Unfortunately the 30days trial period has already passed
for OutlookSpy, which I have used with great fun!

How can I get Mdbview if I do not posses the Exchange 5.5
cd? Is it a free program that can be found on Internet?

Does anybody know whether addins exist that measure things
like "average speed of answer" and "service level" (= nº
emails answered within time limit of say 24hours / total
nº emails received in 24 hours)?

I work in a service call center and I want to find out
this information to asses the quality that we provide to
our customers.

TIA

Martin
-----Original Message-----
You will need to read these properies from the messages in both the Inbox
and Sent Item folders to to find out how the messages are related.
Did you look at the messages with MdbView or OutlookSpy (click IMessage) to
ply with these properties?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


How to accesing the body of the message I can read in your
book I recently bought Sue.

2 months ago Dmitry Streblechenko said that with
Redemption, Extended MAPI or CDO 1.21 it is posible to:

1. read PR_CONVERSATION_INDEX property and find an e- mail
in the Sent Items folder with the same value of
PR_CONVERSATION_INDEX property plus 5 bytes.

2. read PR_MESSAGE_DELIVERY_TIME and
PR_LAST_VERB_EXECUTION_TIME (0x10820040), which last
property is what Outlook uses when it displays "You
replied on..." or "You forwarded this message on...".

How does these extended MAPI properties help me find an
answer to my question?
I need tipos how to interpret these properties!

TIA

MArtin
-----Original Message-----
A sent message that is a reply contains no property related to the arrival
time of the original message that was replied to, but
you
are correct that
the body of the message would contain that date,
assuming
you don't delete
Outlook's automatic reply header.

--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers



"Martin Los" <[email protected]>
wrote
in message
I am afraid the task is a bit more complex. Let me
try
and
explain. I give an easy example:

In the olFolderSentMail I have 20 messages I sent
yesterday; 5 messages are "original" messages (= "New" I
created and sent them) and 15 are responses
(= "Reply"
to
an answer to a received message in my Inbox).

Of those 15 responses I wrote, 12 emails were originally
received the same day (=yesterday), but 3 were received
before yesterday!

Checking messages in olFolderSentMail for ReceivedTime
will give me the time the olFolderSentMail received the
answered mail. BUT IT WILL NOT TELL ME WHEN I
RECEIVED
THE
ORIGINAL MESSAGE I RESPONDED TO!
To check for the date received I guess I should look into
the body of the responded message (or does a property
exist that tells me the received date of a responded
message?).

Any ideas? TIA

Martin
-----Original Message-----
Go with Sue's example, it is much easier - heh i did not
think of that
one, sorry.

Regards.

Lars Roland


On Tue, 10 Aug 2004, Sue Mosher [MVP-Outlook] wrote:

What about using MailItem.ReceivedTime from the Outlook
object model?

"Martin Los" <[email protected]>
wrote in message
Dear Lars:

Since I am not used to MAPI programming, do you have
any
example?

TIA

Martin
-----Original Message-----
On Tue, 10 Aug 2004, Martin Los wrote:

So how can I correct this?
I already have the macro checking the send mail
folder
and
checking for "send date = yesterday". What I miss
is a
check for "received date = yesterday" as well?


You can use MAPI to get to the email and then
use
the
ReceivedTime
method on the mail item.


.


.
 
See http://support.microsoft.com/?kbid=291794
Did you look for available addins at http://www.slipstick.com ?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


Unfortunately the 30days trial period has already passed
for OutlookSpy, which I have used with great fun!

How can I get Mdbview if I do not posses the Exchange 5.5
cd? Is it a free program that can be found on Internet?

Does anybody know whether addins exist that measure things
like "average speed of answer" and "service level" (= nº
emails answered within time limit of say 24hours / total
nº emails received in 24 hours)?

I work in a service call center and I want to find out
this information to asses the quality that we provide to
our customers.

TIA

Martin
-----Original Message-----
You will need to read these properies from the messages in both the Inbox
and Sent Item folders to to find out how the messages are related.
Did you look at the messages with MdbView or OutlookSpy (click IMessage) to
ply with these properties?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


How to accesing the body of the message I can read in your
book I recently bought Sue.

2 months ago Dmitry Streblechenko said that with
Redemption, Extended MAPI or CDO 1.21 it is posible to:

1. read PR_CONVERSATION_INDEX property and find an e- mail
in the Sent Items folder with the same value of
PR_CONVERSATION_INDEX property plus 5 bytes.

2. read PR_MESSAGE_DELIVERY_TIME and
PR_LAST_VERB_EXECUTION_TIME (0x10820040), which last
property is what Outlook uses when it displays "You
replied on..." or "You forwarded this message on...".

How does these extended MAPI properties help me find an
answer to my question?
I need tipos how to interpret these properties!

TIA

MArtin
-----Original Message-----
A sent message that is a reply contains no property related to the arrival
time of the original message that was replied to, but
you
are correct that
the body of the message would contain that date,
assuming
you don't delete
Outlook's automatic reply header.

--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers



"Martin Los" <[email protected]>
wrote
in message
I am afraid the task is a bit more complex. Let me
try
and
explain. I give an easy example:

In the olFolderSentMail I have 20 messages I sent
yesterday; 5 messages are "original" messages (= "New" I
created and sent them) and 15 are responses
(= "Reply"
to
an answer to a received message in my Inbox).

Of those 15 responses I wrote, 12 emails were originally
received the same day (=yesterday), but 3 were received
before yesterday!

Checking messages in olFolderSentMail for ReceivedTime
will give me the time the olFolderSentMail received the
answered mail. BUT IT WILL NOT TELL ME WHEN I
RECEIVED
THE
ORIGINAL MESSAGE I RESPONDED TO!
To check for the date received I guess I should look into
the body of the responded message (or does a property
exist that tells me the received date of a responded
message?).

Any ideas? TIA

Martin
-----Original Message-----
Go with Sue's example, it is much easier - heh i did not
think of that
one, sorry.

Regards.

Lars Roland


On Tue, 10 Aug 2004, Sue Mosher [MVP-Outlook] wrote:

What about using MailItem.ReceivedTime from the Outlook
object model?

"Martin Los" <[email protected]>
wrote in message
Dear Lars:

Since I am not used to MAPI programming, do you have
any
example?

TIA

Martin
-----Original Message-----
On Tue, 10 Aug 2004, Martin Los wrote:

So how can I correct this?
I already have the macro checking the send mail
folder
and
checking for "send date = yesterday". What I miss
is a
check for "received date = yesterday" as well?


You can use MAPI to get to the email and then
use
the
ReceivedTime
method on the mail item.


.


.
 
I will check out these sites. Also I will try to find a
custom solution to get the answer to how to calculate the
average response time of the answered mails and the
service level of the received mails.

Thanks to all for your contributions....will be continued
in the future no doubt!

Martin
-----Original Message-----
See http://support.microsoft.com/?kbid=291794
Did you look for available addins at
http://www.slipstick.com ?
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


Unfortunately the 30days trial period has already passed
for OutlookSpy, which I have used with great fun!

How can I get Mdbview if I do not posses the Exchange 5.5
cd? Is it a free program that can be found on Internet?

Does anybody know whether addins exist that measure things
like "average speed of answer" and "service level" (= nº
emails answered within time limit of say 24hours / total
nº emails received in 24 hours)?

I work in a service call center and I want to find out
this information to asses the quality that we provide to
our customers.

TIA

Martin
-----Original Message-----
You will need to read these properies from the messages in both the Inbox
and Sent Item folders to to find out how the messages are related.
Did you look at the messages with MdbView or OutlookSpy (click IMessage) to
ply with these properties?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


How to accesing the body of the message I can read in your
book I recently bought Sue.

2 months ago Dmitry Streblechenko said that with
Redemption, Extended MAPI or CDO 1.21 it is posible to:

1. read PR_CONVERSATION_INDEX property and find an e- mail
in the Sent Items folder with the same value of
PR_CONVERSATION_INDEX property plus 5 bytes.

2. read PR_MESSAGE_DELIVERY_TIME and
PR_LAST_VERB_EXECUTION_TIME (0x10820040), which last
property is what Outlook uses when it displays "You
replied on..." or "You forwarded this message on...".

How does these extended MAPI properties help me find an
answer to my question?
I need tipos how to interpret these properties!

TIA

MArtin

-----Original Message-----
A sent message that is a reply contains no property
related to the arrival
time of the original message that was replied to, but you
are correct that
the body of the message would contain that date, assuming
you don't delete
Outlook's automatic reply header.

--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers



in message
I am afraid the task is a bit more complex. Let me try
and
explain. I give an easy example:

In the olFolderSentMail I have 20 messages I sent
yesterday; 5 messages are "original" messages (= "New" I
created and sent them) and 15 are responses (= "Reply"
to
an answer to a received message in my Inbox).

Of those 15 responses I wrote, 12 emails were originally
received the same day (=yesterday), but 3 were received
before yesterday!

Checking messages in olFolderSentMail for ReceivedTime
will give me the time the olFolderSentMail received the
answered mail. BUT IT WILL NOT TELL ME WHEN I RECEIVED
THE
ORIGINAL MESSAGE I RESPONDED TO!
To check for the date received I guess I should look
into
the body of the responded message (or does a property
exist that tells me the received date of a responded
message?).

Any ideas? TIA

Martin
-----Original Message-----
Go with Sue's example, it is much easier - heh i did
not
think of that
one, sorry.

Regards.

Lars Roland
 
Back
Top