Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Exchange
2000.active.directory
2000.admin
2000.announcements
2000.app.conversion
2000.applications
2000.clients
2000.clustering
2000.connectivity
2000.development
2000.documentation
2000.general
2000.information.store
2000.interop
2000.kms
2000.misc
2000.protocols
2000.realtime.collabo.
2000.setup
2000.transport
2000.win2000
admin
application.conversion
applications
clients
clustering
connectivity
design
development
misc
mobility
setup
tools
  
 
date: 13 Jun 2006 02:43:23 -0700,    group: microsoft.public.exchange.development        back       


CDO : Modifying Sender property of the message object in C#   
Hi,

I used a code inspired by the article :
http://support.microsoft.com/?kbid=239568

But the modified sender property does not seem to be taken in account.
The message is sent correctly but with the connected user account, not
the one set on the sender property.

Here's the concerned part of the code :

MAPI.AddressLists oAddrLists;
MAPI.AddressList oAddrList;
MAPI.AddressEntries oAddrEntries;
MAPI.AddressEntryFilter oAddrEntryFilter;
oAddrLists = (MAPI.AddressLists)sessionExchange.AddressLists;
oAddrList = (MAPI.AddressList)oAddrLists.get_Item(1);
oAddrEntries = (MAPI.AddressEntries)oAddrList.AddressEntries;
oAddrEntryFilter = (MAPI.AddressEntryFilter)oAddrEntries.Filter;
oAddrEntryFilter.Name = "name of the exchange account";
oMsg.Sender = (MAPI.AddressEntry)oAddrEntries.GetFirst();
oMsg.Update(true,false);
oMsg.Send(false, false, 0);

Do you have an idea of what is wrong here ?

Thanks,
Sebastien
date: 13 Jun 2006 02:43:23 -0700   author:   unknown

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us