Important: |
---|
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist. |
This function returns the software-configurable network address that was stored in the registry for an NIC when it was installed in the computer.
VOID NdisReadNetworkAddress( OUT PNDIS_STATUS Status , OUT PVOID* NetworkAddress , OUT PUINT NetworkAddressLength , IN NDIS_HANDLE ConfigurationHandle );
Parameters
Value | Description |
---|---|
NDIS_STATUS_SUCCESS | The caller can use the address returned at NetworkAddressfor its NIC. |
NDIS_STATUS_FAILURE | There was no NIC address information available in the caller's registry Parameterskey, or the value stored was not a string. |
Remarks
For PC Card NICs, if no network address was specified in the registry, NDIS reads the network address from the card's attribute space and stores it in the registry.
This function searches the registry Parameterskey designated by the specified ConfigurationHandlefor the keyword NetworkAddress, converts the value of this string-type entry into a sequence of byte integers, and stores the requested information internally. The storage that NDIS allocates for such an address remains valid until the NIC driver calls NdisCloseConfiguration, which frees the memory.
The caller cannot use the variable at NetworkAddressas a pointer unless this function returns NDIS_STATUS_SUCCESS at Status.
The installation program for an NIC that supports software-configurable network addressing stores a value entry named with the NetworkAddresskeyword in the appropriate XXX\ DriverName\Parameterskey of the registry.
An NIC installer usually stores the value of a NetworkAddressentry in the registry as a string of hexadecimal digits. Optionally, an installer can store such an address as a string of paired digits, with each pair separated from the next by a hyphen. This function discards hyphens and converts each such pair into a single byte.
In either form, this function converts the address specified as a string, one character at a time, into the equivalent integer until the string is exhausted.
In the Windows CE registry, such an installed address string contains Unicode characters.
A driver that calls this function runs at IRQL PASSIVE_LEVEL.
Requirements
Runs on | Versions | Defined in | Include | Link to |
---|---|---|---|---|
Windows CE OS | 2.0 and later | Ndis.h |
Note This API is part of the complete Windows CE OS package as provided by Microsoft. The functionality of a particular platform is determined by the original equipment manufacturer (OEM) and some devices may not support this API.
See Also
NdisCloseConfiguration, NdisOpenConfiguration
Last updated on Tuesday, July 13, 2004