<div class="content"><p> </p><p>The EvtRpcGetClassicLogDisplayName (Opnum 28) method obtains
a descriptive name for a channel.</p><dl>
<dd>
<div><pre> error_status_t EvtRpcGetClassicLogDisplayName(
   /* [in] RPC_BINDING_HANDLE binding, {the binding handle will be generated by MIDL} */
   [in, range(1, MAX_RPC_CHANNEL_NAME_LENGTH), string] 
     LPCWSTR logName,
   [in] LCID locale,
   [in] DWORD flags,
   [out] LPWSTR* displayName
 );
</pre></div>
</dd></dl><p><b>binding: </b>An RPC binding handle as specified in
section <span><a href="1285c318-9f8c-4c6a-a963-7999557bf8d8" data-linktype="relative-path">2.2.21</a></span>.</p><p><b>logName: </b>The channel name for which the
descriptive name is needed.</p><p><b>locale: </b>The locale, as specified in <span><a href="../ms-gpsi/8ac65057-0663-45e5-9718-f490e87945dc" data-linktype="relative-path">[MS-GPSI]</a></span>
<span><a href="../ms-gpsi/70e94400-9a48-4dc7-a074-b9cb1ba6fad3" data-linktype="relative-path">Appendix A</a></span>,
to be used for localizing the log.</p><p><b>flags: </b>A 32-bit unsigned integer that MUST be
set to one of the following values: </p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>0x0</p>
  </td>
  <td>
  <p>If a locale is specified, that locale will be used and
  no fallback locale will be attempted if the locale is not present.</p>
  </td>
 </tr><tr>
  <td>
  <p>0x100</p>
  </td>
  <td>
  <p>If set, instructs the server to pick the best locale,
  if the locale specified by the <i>locale</i> parameter is not present. Please
  see the following processing rules for more information on how the server
  picks the best locale.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>displayName: </b>Returned display name.</p><p><b>Return Values: </b>The method MUST return ERROR_SUCCESS
(0x00000000) on success; otherwise, it MUST return an implementation-specific
nonzero value as specified in <span><a href="../ms-erref/1bc92ddf-b79e-413c-bbaa-99a5281a6c90" data-linktype="relative-path">[MS-ERREF]</a></span>.</p><p>In response to this request from the client, for a
successful operation, the server MUST attempt to retrieve a display name for a
channel. In <span><a href="../ms-even/55b13664-f739-4e4e-bd8d-04eeda59d09f" data-linktype="relative-path">[MS-EVEN]</a></span>
section <span><a href="../ms-even/6dda2ef2-2efe-4534-bbeb-07ff44f46a10" data-linktype="relative-path">3.1.1.2</a></span>,
there are two configuration entries for a classic event log: DisplayNameFile
and DisplayNameID. The server tries to use the log name passed here to find the
log entry in the registry and then locate the DisplayNameID and
DisplayNameFile. The DisplayNameID is the message ID for the display name. The
file which is pointed at by DisplayNameFile contains the localized string for
the display name. The server uses the messageId and locale as the combination
key to look for the string inside the file and then retrieve the classic event
log display name. The server verifies that the channel name, as specified by
the <i>logName</i> parameter, is a known classic event log. If the <i>logName</i>
parameter does not specify a registered event log (the log name can&#39;t be
located in the registry described in [MS-EVEN]), the server MUST fail the
method with the error ERROR_NOT_FOUND (0x00000490). If the server can&#39;t find
the DisplayNameID or the DisplayNameFile, the server SHOULD fail the method
with the error ERROR_INVALID_DATA (0x0000000D).</p><p>If the locale is not specified (that is, the caller passes
zero for the locale parameter) and the <i>flags</i> parameter is 0x0, the
server MUST substitute the locale of its own execution thread as the value of
the locale parameter.</p><p>If the display name is not present in the specified <i>locale</i>
as specified above and the <i>flags</i> parameter is set to 0x100, the server
makes a best effort attempt to find a localized display name string by
following these steps:</p><ol><li><p><span>    </span>The server
SHOULD attempt to find a fallback locale with the same base language which does
contain the localized display name.<a id="Appendix_A_Target_68"></a><a aria-label="Product behavior note 68" href="65f22d62-5f0f-4306-85c4-50fb9e77075b#Appendix_A_68" data-linktype="relative-path">&lt;68&gt;</a> For
example, if the caller requested the U.S. English &#34;en-US&#34; locale but
the display name was only available in another &#34;en&#34; prefixed locale
such as the British English &#34;en-GB&#34; locale, the server would return
the British English version of the display name.</p>
</li><li><p><span>    </span>Using the
fallback locale, the server SHOULD attempt to find a localized display name
string by searching the appropriate DisplayNameFile in the same manner as
specified above.</p>
</li><li><p><span>    </span>If the server
cannot determine an appropriate fallback locale or cannot find a localized
display name string using the fallback locale, the server MUST return
ERROR_NOT_FOUND (0x00000490).</p>
</li></ol><p>The server SHOULD validate the flags to ensure that no flags
are present other than 0x0 and 0x100.<a id="Appendix_A_Target_69"></a><a aria-label="Product behavior note 69" href="65f22d62-5f0f-4306-85c4-50fb9e77075b#Appendix_A_69" data-linktype="relative-path">&lt;69&gt;</a></p><p>Otherwise, the server MUST fail the method with the error
ERROR_INVALID_PARAMETER (0x00000057).</p><p>This API only succeeds if called for a log name that is
exposed by the obsolete Eventlog Remote protocol. If called on logs that are
not exposed by the obsolete Eventlog Remote protocol, the method will fail with
the error ERROR_NOT_FOUND (0x00000490). For more information, see section <span><a href="77e3552a-90e8-4dae-9612-99ee54ec1f6d" data-linktype="relative-path">3.1.1.6</a></span>.</p><p>The server MUST return a value indicating success or failure
for this operation.</p></div>