<div class="content"><p> </p><p>The ElfrNumberOfRecords (Opnum 4) method instructs the
server to report the number of records currently in the <span><a href="e74c8719-c30e-4f7a-bef7-82753cc0e159#gt_bb3fad7e-60bf-46d4-9c3f-7caea47a743e" data-linktype="relative-path">event log</a></span>.
</p><dl>
<dd>
<div><pre> NTSTATUS ElfrNumberOfRecords(
   [in] IELF_HANDLE LogHandle,
   [out] unsigned long* NumberOfRecords
 );
</pre></div>
</dd></dl><p><b>LogHandle: </b>Handle to an event log. This parameter is
a server context handle, as specified in section <span><a href="de54bfbc-fbe4-43b8-b8e1-b8a6b2189604" data-linktype="relative-path">2.2.6</a></span>.</p><p><b>NumberOfRecords: </b>Total number of records in the
specified event log.</p><p><b>Return Values: </b>The method MUST return STATUS_SUCCESS
(0x00000000) on success; otherwise, it MUST return an implementation-based,
nonzero NTSTATUS value 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, the server MUST
first check that the handle is valid. The server MUST fail the operation with
the error STATUS_INVALID_HANDLE (0xC0000008) if the handle is invalid.</p><p>If the handle is valid, the method MUST retrieve the number
of records in the associated log and return the number via the <i>NumberOfRecords</i>
parameter, and return success.<a id="Appendix_A_Target_37"></a><a aria-label="Product behavior note 37" href="4acc4fbc-1378-4120-83d1-cfb4ae0240e0#Appendix_A_37" data-linktype="relative-path">&lt;37&gt;</a> This call
MUST NOT update the internal state of the server. </p></div>