View Single Post
  #3  
Old November 7th 06, 12:03 AM posted to microsoft.public.outlook.program_vba
P Hoppe
external usenet poster
 
Posts: 3
Default How to add a UserProperty to a MAPIFolder?

What exactly need to be done to the MailItem for this to work?

I have the following code (C#):
dummyMailItem.UserProperties.Add("Dummy", Outlook.OlUserPropertyType.olText,
true, System.Type.Missing);
dummyMailItem.Subject = "Dummy";
dummyMailItem.Body = "Dummy";
dummyMailItem.To = ";
dummyMailItem.Save();
//dummyMailItem.Delete();

However, the mail item isn't added to the folder, and the user property
isn't added as user propertiy column.

Why not?

Ads