怎样用 CDO 1.2.X 访问 Exchange ,问题很急! ( 积分: 100 )

  • 主题发起人 主题发起人 glsky
  • 开始时间 开始时间
G

glsky

Unregistered / Unconfirmed
GUEST, unregistred user!
老板让我们实现客户机访问远端的exchange ,要求能发信,浏览目录,创建目录,打开信件,<br>我看了一下,最好是用CDO, 以前没用过,请大家指教,最好有实例!谢谢!
 
老板让我们实现客户机访问远端的exchange ,要求能发信,浏览目录,创建目录,打开信件,<br>我看了一下,最好是用CDO, 以前没用过,请大家指教,最好有实例!谢谢!
 
下面这个网址有你要的东西,有很多示例代码,我测试过,可以下载<br><br>http://www.imibo.com/imidev/delphi/les/cdoless.html<br><br><br><br>CDO 1.2.1 in DELPHI<br>(MS Exchange Server 5.5 Edition / Microsoft Exchange Server 2000/2003 compatibles / DELPHI 5 Edition / DELPHI 6 / DELPHI 7 compatibles)<br><br>The DELPHI sources of CDO 1.2.1 in DELPHI examples are delivered via electronic Internet download after registration<br><br><br>--------------------------------------------------------------------------------<br><br>Description: Application as Lesson Source <br>PART I<br>Logging On and working with GAL &nbsp;<br>Example # 1 <br>Log in MS Exchange Server and<br>Query User Identity <br><br>How to:<br><br>Use CDO.Session Object <br>Use Session.Logon <br>Use Session.CurrentUser <br>Use AddressEntry <br>Find type of AddressEntry <br>Work with Fields collection <br>Work with Field property <br>Use Field.ID propery <br>Get Field.Value by MAPI TAG <br>Use Session.LogOff <br>... <br> Example1<br>(221 KB)<br> In package <br>Example # 2 <br>Retrieve MS Exchange GAL<br>(Global Address List) <br><br>global address list<br>(GAL) A MAPI address book container that holds recipient entries for an entire organization and is available to all e-mail users in that organization.<br><br>Include some steps<br>from Example #1 and<br>How to:<br><br>Get Global Address List <br>Use AddressEntries <br>Use GetFirst <br>Use GetNext <br>Link AddressEntry.DisplayType with image <br>Get Recipient Display Name <br>Get Recipient SMTP e-mail address <br>... <br> Example2<br>(241 KB) <br> In package<br> <br>Example # 3 <br>Retrieve MS Exchange &quot;Light&quot; Hierarchy<br>(by Global Address List)<br><br>Hierarchy Viewer<br>A hierarchy viewer is a user interface component that is used for displaying folder and address book container hierarchy tables. Hierarchy viewers can display members of the hierarchy at different levels, expanding and contracting each level on demand.<br><br>How to:<br><br>Get Global Address List <br>Use AddressEntries <br>Build &quot;Light&quot; Tree <br>... <br> Example3<br>(226 KB) <br> In package<br> <br>Example # 4 <br>Writing a small Hierarchy Viewer <br><br>Now we will write small GAL Hierarchy Viewer. What must do it:<br> - must show GAL<br> - must show Hierarchy<br> - must show Organization<br> &nbsp;- must show Sites<br> &nbsp;- must show Containers in each Site<br> &nbsp;- must show recipients in each container<br> &nbsp;<br> Example4<br>(250 KB)<br> In package<br> <br>PART II<br>Working with Private Information Store (Mailbox) &nbsp;<br>Example # 5 <br>Log in MS Exchange Server and<br>Getting Exchange Private Store Tree <br><br>In this example we will write small Exchange Private Store (mailbox) Hierarchy Viewer. <br>How to:<br><br>Open Mailbox <br>Find Exchange Private Store <br>Open Exchange Private Store <br>InfoStores collection <br>Use InfoStore Object <br>Find 'RootFolder' <br>Enumerate IPM Subtree <br>Folders Collection <br>etc.. <br> Example5<br>(227 KB)<br> In package<br> <br>Example # 6 <br>Getting Exchange Mailbox and enumerate items (messages) in each folder &nbsp;<br><br>How to:<br><br>Get Container Class<br>ex. IPM.Note, IPM.Contact, IPM.Task... <br>Enumerate messages in MAPI Folder <br>Get Message Subject <br>How to get Message properties <br>Work with Fields Collection <br>Work with fields <br>etc.. <br> Example6<br>(251 KB)<br> In package<br> <br>Example # 7 <br>How to build SIMPLE Mailbox reader (agent) with CDO and DELPHI <br><br> <br><br>The sample (MAIL Reader) demonstrates how-to:<br><br>Login to Exchange Server <br>Get own e-mail address <br>Get available Information Stores <br>Get and work with Information Store Folders Collection <br>Get and work with Folder <br>Get and work with Messages (enumerate, read, delete, make it as read or unread) <br>Work with fields <br>and more <br> Example7<br>(270 KB)<br> In package<br> <br> BY REQUEST<br>(You ask- we create) <br> <br>#1 <br>How to create Appointment/Meeting from DELPHI &nbsp; <br><br>This example show how to create and send Meeting request with CDO and DELPHI. <br><br>The example use as basis Example # 7. &nbsp;<br><br>This is First Lesson created for &quot;By Request&quot; <br><br> &nbsp; &nbsp;CDOAppt<br>(279 KB)<br> In package<br> <br> &nbsp; &nbsp; &nbsp; &nbsp; <br>DELPHI 5 Sources for &nbsp;PART I &amp; II <br>is available after registration <br>(381 KB, Password protected) Register and unlock it<br><br><br> <br><br>Please see also<br> Installing CDO with Outlook &nbsp;and<br> Where to acquire the CDO Libraries (all versions) &nbsp;- http://support.microsoft.com/default.aspx?scid=kb;en-us;171440<br> <br>See &quot;Down to the Metal&quot;:<br> &nbsp;Extended MAPI in DELPHI<br> <br>[Other Tools][Home]
 
hello, chenybin<br>thank you very much!<br>但是我怎样才能得到其源码呢,只能下载exe文件, 如果你有,可以mail 给我吗!<br>邮箱: gljjh@163.com<br>在下急用!分不够我再加!
 
http://www.imibo.com/imidev/delphi/les/index.html#DELPHI%205%20Sources%20for%20%20PART%20I<br><br>这里好像可以下到部分代码,网站如果你去看过了应知道是需要注册的,<br><br>很遗憾,我也是从网上找的资料,建议看看MSDN或者其他的官方的东西<br><br>就是这个http://support.microsoft.com/default.aspx?scid=kb;en-us;171440 网址,我刚刚检查过了,可以访问
 
后退
顶部