File: rsSamplesEmail.htm

package info (click to toggle)
office2003-schemas 1.0%2Bds-1
  • links: PTS, VCS
  • area: non-free
  • in suites: bookworm, forky, sid, trixie
  • size: 42,304 kB
  • sloc: javascript: 2,429; makefile: 29
file content (15 lines) | stat: -rw-r--r-- 11,685 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<html dir="ltr"><head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<META HTTP-EQUIV="assetid" CONTENT="HV01082289"><META NAME="lcid" CONTENT="1033"><title>Email Sample</title><link rel="stylesheet" type="text/css" href="office10.css"><script type="text/javascript" language="Javascript" src="ExpCollapse.js"></script><script type="text/javascript" language="JavaScript" src="inline.js"></script></head><body><p id="ExpandAllLine" class="ExpFav"><a href="#" onclick="ExpandAll()" onkeypress="ExpandAll()" class="DropDown"><img id="picHeader" border="0" src="expandtri.gif" alt="Show All"><span id="ExpandAll">Show All</span></a></p><h1>Email Sample</h1><p>The Email research service integrates a directory search into Microsoft® Office 2003 applications. It enables a search based on e-mail name, first name, last name, or full name.</p><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Adapting the Email research service to your network configuration</a></p><div id="ExpCol" class="collapsed" border="0"><p>This research service uses the Active Directory® directory service on a Microsoft Windows® network. Before you run this sample, you will have to modify the connection string <b class="bterm">sLDAP</b> in email.asmx.cs to adapt the service to your network, which must support the Lightweight Directory Access
Protocol (LDAP). Once you have modified the connection string, you can build the research service.</p>
		</div><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Building the Email research service</a></p><div id="ExpCol" class="collapsed" border="0"><p>The Research Service SDK provides the email.asmx and email.asmx.cs source files for the Email research service. This section describes how to build the Email research service as a Web service based on these files.</p><div class="ind"><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Requirements</a></p><div id="ExpCol" class="collapsed" border="0"><ul><li>Microsoft Office 2003</li><li>Microsoft .NET Framework 1.0 or later</li><li>Microsoft .NET Framework 1.0 Software Development Kit, or a later release</li><li>Microsoft Internet Information Services (IIS) 5.0 or later</li></ul><p><b>Note</b>  IIS should be installed before you set up the Microsoft .NET Framework SDK. If you have installed or re-installed IIS after setting up the Microsoft .NET Framework SDK, you will experience unexpected behavior when you try to view ASP.NET pages. To fix this, register ASP.NET with IIS again by running the aspnet_regiis.exe utility. For more information, see Knowledge Base article 306005 , "<a href="http://r.office.microsoft.com/r/rlidAWSContentRedir?AssetID=XT010971891033&amp;CTT=11&amp;Origin=HV010822891033" target="_new">HOWTO: Repair IIS Mapping After You Remove and Reinstall IIS</a>.”</p></div></div><div class="ind"><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Build the research service</a></p><div id="ExpCol" class="collapsed" border="0"><ol><li>Do one of the following: <ul><li>If you have installed the Research SDK on the computer that hosts the IIS server <i>ServerName</i>, go to step 2.</li><li><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">If you have installed the Research SDK on a computer other than <i>ServerName</i>:</a></p><div id="ExpCol" class="collapsed" border="0"><ol><li>Create a folder named Email Sample on <i>ServerName</i>.<p><b>Note</b>  To avoid access problems when running the Email Web service, do not place the Email Sample folder in the  My Documents folder.</p></li><li>From the computer that the SDK is installed on, copy the contents of the Email Sample folder (under <i>Drive</i>:\Program Files\Microsoft Office 2003 Developer Resources\Microsoft Office 2003 Research Service SDK\Samples) to the Email Sample folder on <i>ServerName</i>.</li></ol></div></li></ul></li><li><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Map the Email Sample folder to a virtual directory named EmailService on the IIS server <i>ServerName</i>.</a></p><div id="ExpCol" class="collapsed" border="0"><ol><li>From the Windows <b class="ui">Start</b> menu, click <b class="bterm">Control Panel</b>, and then double-click <b class="ui">Administrative Tools</b>.</li><li>Double-click <b class="ui">Internet Information Services</b>.</li><li>In the Internet Information Services folder tree, expand the folders for the local computer, the <b class="ui">Web Sites</b> directory, and the <b class="ui">Default Web Site</b>.</li><li>Create a new virtual directory EmailService by right-clicking <b class="ui">Default Web Site</b> and selecting <b class="ui">New</b> and <b class="ui">Virtual Directory</b>. Follow the instructions on the <b class="ui">Virtual Directory Creation Wizard</b>.</li></ol></div></li><li>From the Windows command prompt on the <i>ServerName</i> computer, change to the Email Sample\Email folder and run make.bat to compile and build the Web service. The assembly file Email.dll will be generated in the Email Sample\Bin folder.<p><b>Note</b>  Make.bat uses the Microsoft Visual C#® command-line compiler, csc.exe, which is available as part of the Microsoft .NET Framework SDK. If necessary, modify make.bat  to include a search path for the compiler.</p></li></ol></div></div></div><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Configuring the smart tag</a></p><div id="ExpCol" class="collapsed" border="0"><p>The research service uses a client-side smart tag to provide a richer set of features to interact with documents. If the smart tag is not installed, the research service will continue to function normally, with the exception that the smart tag menu items will not be available.</p><p>To install the smart tag on a client computer:</p><ol><li>Do one of the following: <ul><li>If you have installed the Research Service SDK on the client computer, go to step 2 below.</li><li><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">If you have installed the Research Service SDK on a computer other than  the client computer:</a></p><div id="ExpCol" class="collapsed" border="0"><ol><li>Create a folder named Email Sample on the client computer.</li><li>From the computer that the SDK is installed on, copy the contents of the Email Sample folder (under <i>Drive</i>:\Program Files\Microsoft Office 2003 Developer Resources\Microsoft Office 2003 Research Service SDK\Samples) to the Email Sample folder on the client computer.</li></ol></div></li></ul></li><li>On the client computer, open a command prompt and navigate to Email Sample\Email\EmailContactSmartTag.</li><li>Register the smart tag DLL with the following command-line command:
<pre><code>regsvr32 CorpContact.dll</code></pre>
</li><li>A message box will appear stating, "DllRegisterServer in corpcontact.dll succeeded." Click <b class="ui">OK</b>.</li><li>To notify Office that this smart tag is available,  type the following at the command line:<pre><code>regedit CorpContact.reg</code></pre>
You will be prompted to confirm that you want to add this information into the registry.
 Click <b class="ui">Yes</b>.</li><li>A message box will appear stating, "Information in corpcontact.reg has been successfully entered into the registry." Click <b class="ui">OK</b>.</li><li>Reboot the client computer.</li></ol></div><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Using the Email research service</a></p><div id="ExpCol" class="collapsed" border="0"><p>Before you can search on the Email research service for the first time, you must add the research service to the <b class="bterm">Research</b> task pane by using the URL http://<i>ServerName</i>/EmailService/Email/email.asmx. For more information about adding a research service, see <a href="rsAddingUI.htm" id="HV01082279" lcid=" ">Adding Services through the Office User Interface</a>.</p><h2>Search the Email research service</h2><p>This section assumes the Email research service uses Active Directory within a Windows network.</p><ol><li>On the <b class="bterm">Research</b> task pane, under <b class="ui">Search for</b>, type the e-mail address, first name, last name, or full name of the person you are searching for in Active Directory. You can enter <b class="bterm">*</b> as a wildcard character.</li><li>You can specify that the returned results should be sorted by full name, last name, or first name, and in ascending or descending order.</li></ol></div><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Design of the Email research service</a></p><div id="ExpCol" class="collapsed" border="0"><p>The Email research service specifies two Web methods: <b class="bterm">Query</b> and  <b class="bterm">Registration</b> under the <b class="bterm">Search</b> namespace. The Web page http://<i>ServerName</i>/EmailService/Email/email.asmx provides a brief description and a hyperlink to the formal definition of each of these methods.</p><div class="ind"><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show"><b class="bterm">Query</b></a></p><div id="ExpCol" class="collapsed" border="0"><p>This method searches the Active Directory service of a sample domain for a specified e-mail name, first name, last name, or full name. It returns a query response to the <b class="bterm">Research</b> task pane, which will display the search results in the specified sort criteria. The query response supports the <a href="rsxsdResponse.htm" id="HV01084530" lcid=" ">Microsoft.Search.Response Schema</a>.</p> <p>To adapt this sample to search other networks  that support LDAP, modify the connection string for the constant <code>sLDAP</code>. You can also modify the fields to be displayed in the search results with the <b class="bterm">GetSearchResult</b> method.</p></div></div><div class="ind"><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show"><b class="bterm">Registration</b></a></p><div id="ExpCol" class="collapsed" border="0"><p>This method is called when you first add the Email research service to the task pane. At this point,  the service sends a registration request. The <b class="bterm">Registration</b> method always returns a registration response. The registration response supports the  <a href="rsxsdRegistrationResponse.htm" id="HV01084526" lcid=" ">Microsoft.Search.Registration.Response Schema</a>.</p></div></div><p>For more information about the research service  schemas, see <a href="rsReferenceSchemas.htm" id="HV01082292" lcid=" ">XML Schemas Overview</a>.</p></div><center><a href="XMLSchemaCopyright_HV01147162.htm">&copy;2003-2004 Microsoft Corporation. All rights reserved.</a>  

Permission to copy, display and distribute this document is available at: <a 

href="http://r.office.microsoft.com/r/rlidAWSContentRedir?AssetID=XT010988631033&amp;CTT=11&amp;Origin=HV011232471033" 

target="_new">http://msdn.microsoft.com/library/en-us/odcXMLRef/html/odcXMLRefLegalNotice.asp</a></center></body></html>