Hi all,

I want to extract messages from the mailbox / sent items folder.

Here's my code to extract email's for the last week (Delphi late-binding):
var vGWBox, vGWFind: Variant
vGWBox := vGWLog.MailBox;
vGWFind := vGWBox.Messages;

// MailBox folder content

// Sent Items folder content
else if bOutBox then vGWFind.Find('(MAIL) AND (BOX_TYPE=OUTGOING) AND (CREATE_DATE>=TODAY - 7)');

The problem is that there's too much messages returned.
That is, I need to exclude all classified msgs.
So, if a message is moved to a personal cabinet folder, I don't want to see it anymore in my results.

I've tried AllMessages instead of MailBox and it is closer to expected results :
//vGWBox := vGWLog.MailBox;
//vGWFind := vGWBox.Messages.Find(s);
vGWFind := vGWLog.AllMessages.Find(s);

Using AllMessages, the filter is considered (but again, it returns all classified msgs, which are not wanted...).
Using MailBox.Messages bypass the filter (it returns all messages received / sent since the installation of GW)

Why MailBox object doesn't match with MailBox folder in GroupWise User Interface?

Thanks in advance for help