
MAPI access to Sent Items folder???
I've got a few applications that make use of vb mapi controls to send
messages. Problem is, my Exchange folders are getting a bit full. I've
written some code to delete messages > 7 days old using the .fetch function.
MAPISession1.SignOn
With MAPIMessages1
.SessionID = MAPISession1.SessionID
.FetchMsgType = ""
.FetchUnreadOnly = False
.Fetch
For i = .MsgCount - 1 To 0 Step -1
.MsgIndex = i
If CDate(.MsgDateReceived) < Now() - 7 Then
.Delete
End If
Next i
End With
MAPISession1.SignOff
Documentation states that the default for .FetchMsgType is IPM, which works,
but returns only the inbox.
I'd like to scan the Sent Items folder, any ideas?
What should the value of .FetchMsgType be?