1 2 3 4 5 6 7 8 9 10
|
<html dir="ltr"><head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<META HTTP-EQUIV="assetid" CONTENT="HV01082274"><META NAME="lcid" CONTENT="1033"><title>Building a Translation Service</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>Building a Translation Service</h1><p>Language-translation services represent a special category of research services and involve some special implementation procedures in addition to the steps discussed in <a href="rsRegistrationInterface.htm" id="HV01082272" lcid=" ">Handling Registration Requests</a> and <a href="rsQueryInterface.htm" id="HV01082269" lcid=" ">Handling Queries</a>.</p><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Registering a translation service</a></p><div id="ExpCol" class="collapsed" border="0"><p>If you want to provide bidirectional translation support<nbsp />— for example, from English to Spanish and from Spanish to English<nbsp />— you need to register a separate service for each direction.</p>
<p>Certain elements in the registration response packet must contain particular values, as shown in the following table.</p><table><tr><th>Element</th><th>Value</th></tr><tr><td><b class="bterm">Name (of Provider)</b></td><td>The provider name cannot contain the ampersand character (&).</td></tr><tr><td><b class="bterm">Data</b></td><td>The <b class="bterm">Data</b> element contains the locale ID values for the "from" language and the "to" language, followed by the value "1" to indicate a regular word-by-word translation service, for example, <code>1033/3082/1</code> for English to Spanish. The value "2" in the third position indicates a whole-document translation service. (See the note following this table.) Other values you may see in the third position (for example, 4 and 8) are for internal use only.</td></tr><tr><td><b class="bterm">Display</b></td><td>Hidden.</td></tr><tr><td><b class="bterm">Category</b></td><td>REFERENCE_TRANSLATION.</td></tr></table><p><b>Note</b> If you examine the list of translation services in the registry, you may notice some services that have the phrase "(Whole Document)" in their name. These services use an API distinct from the Research Web service methods discussed in this SDK to translate entire HTML pages. For additional information, see the <a href=" " target="_new">Translation Dictionaries Content Development Kit</a> in the Microsoft Developer Network (MSDN) Library. This CDK remains unchanged for Microsoft® Office 2003.</p></div><p><a href="#" class="DropDown" onclick="Outline2()" onkeypress="Outline2()"><img border="0" src="blueup.gif" alt="Show">Querying a translation service</a></p><div id="ExpCol" class="collapsed" border="0"><p>The response to a translation query supports only the <b class="bterm">Microsoft.Search.Response.Content</b> namespace. For properly formatted results, return only a single <b class="bterm">Content</b> element. If the response packet contains elements from the <b class="bterm">Microsoft.Search.Response.Document</b> or <b class="bterm">Microsoft.Search.Response.Form</b> namespaces, the <b class="bterm">Research</b> task pane disregards those elements. If the response packet contains multiple <b class="bterm">Content</b> elements, the <b class="bterm">Research</b> task pane displays a new service heading for each <b class="bterm">Content</b> element. This layout may be misleading to the user.</p><p><p><b>Notes</b></p> <ul><li>The Office 2003 version of the <b class="bterm">Research</b> task pane does not pass the <b class="bterm">RequeryContext</b> and <b class="bterm">ServiceParameters</b> elements in queries sent to a translation service. The <b class="bterm">Query</b> Web method of a translation service should not check for these elements. For more information about these elements, see <a href="rsQueryInterface.htm" id="HV01082269" lcid=" ">Handling Queries</a>. </li><li>The <b class="bterm">Research</b> task pane disregards the <b class="bterm">providerRevision</b> attribute in translation query responses. Therefore, translation services cannot easily advertise the availability of updates to users. However, users can initiate an update of the translation service manually from the <b class="bterm">Research Options</b> dialog box. For more information about the use of the <b class="bterm">providerRevision</b> attribute, see <a href="rsUpdating.htm" id="HV01082282" lcid=" ">Updating and Removing Services</a>.</li></ul></p></div><center><a href="XMLSchemaCopyright_HV01147162.htm">©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&CTT=11&Origin=HV011232471033"
target="_new">http://msdn.microsoft.com/library/en-us/odcXMLRef/html/odcXMLRefLegalNotice.asp</a></center></body></html>
|