Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Outlook / Programming VBA / July 2004

Tip: Looking for answers? Try searching our database.

Create user defined fields for contact using MAPI

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Isaac Varghese - 29 Jul 2004 18:09 GMT
I'm trying to add a custom property(user defined fields) to a contact
item in Outlook in C# using MAPI.

And i'm successful in that also.Also i'm able to read that property
afterwards.

I use the following code to set create the properties.
######################################################
MAPI.Field fld = (MAPI.Field)flds.Add("CONTACT_ID",MAPI.CdoFieldType.CdoString,"","0420060000000000C000000000000046");

fld.Value ="111111";

#########################################

But my problem is when i open the contact card and check the ALL
fields tab i can't see this property.
Where can i see the properties set using MAPI??I'm i doing anything
fundamentally  wrong.

Any help in this direction is appreciated.

Thanks in Advance
Isaac Varghese
Dave Kane [MVP - Outlook] - 29 Jul 2004 23:39 GMT
You've added a custom field to the item in the message store, but the standard Outlook contact form doesn't know anything about that field. If you want the form to display the value you will need to edit the form definition. If you just want a visual indicator for your custom field you can add that field to folder and then create or modify a table style view to include that field. Or you can use OutlookSpy (http://www.dimastr.com/outspy/) to see all the fields on the item

> I'm trying to add a custom property(user defined fields) to a contact
> item in Outlook in C# using MAPI.
[quoted text clipped - 19 lines]
> Thanks in Advance
> Isaac Varghese
Tom Rizzo [MSFT] - 31 Jul 2004 17:27 GMT
Easiest thing is to go into Outlook for your folder, open the Field Chooser
and add a new field with the same name as your custom field (CONTACT_ID).
Drag and drop the field into your view and you should see your values.

Tom

Signature

Looking for a good book on programming Exchange, Outlook, ADSI and
SharePoint?  Check out http://www.microsoft.com/MSPress/books/5517.asp

This posting is provided "AS IS" with no warranties, and confers no rights.

> You've added a custom field to the item in the message store, but the standard Outlook contact form doesn't know anything about that field. If you
want the form to display the value you will need to edit the form
definition. If you just want a visual indicator for your custom field you
can add that field to folder and then create or modify a table style view to
include that field. Or you can use OutlookSpy
(http://www.dimastr.com/outspy/) to see all the fields on the item

> > I'm trying to add a custom property(user defined fields) to a contact
> > item in Outlook in C# using MAPI.
[quoted text clipped - 5 lines]
> > ######################################################
> > MAPI.Field fld = (MAPI.Field)flds.Add("CONTACT_ID",MAPI.CdoFieldType.CdoString,"","0420060000
000000C000000000000046");

> > fld.Value ="111111";
> >
[quoted text clipped - 9 lines]
> > Thanks in Advance
> > Isaac Varghese
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.