I have managed to do what I was trying to do without the password, with
the following code :
oNS.Logon(strUserName, System.Reflection.Missing.Value, false, true);
Now I need to do something a bit more difficult, I need to create a new
folder called archive programmatically and move the emails in my inbox
to it in a for loop.
Outlook.MailItem oMsg;
int i;
//Loop through each message
for (i = 1; i < oItems.Count + 1; i++)
{
oMsg = (Outlook.MailItem)oItems.Item(i);
//move msg to archive folder
}
*** Sent via Developersdex
http://www.developersdex.com ***