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.
A version of this page is also available for
4/8/2010

Windows CE 3.0 and later supports the registry key, HKEY_LOCAL_MACHINE\Comm\< Adapter Name >\Parms\Tcpip\DhcpSendOptions, which allows you to send options to the DHCP server. These options are appended to the DHCP packet. Windows Embedded CE does not attempt to parse the data, but just copies it into the packet.

Under this registry key, you can create additional keys and set particular values in binary form that you want to exchange with the server.

Values are created under this key. These values have the names of the options to send.

The format of the option data must include type and length field, as per RFC 1533.

The following list shows the rules that you must follow when using the DhcpSendOptions registry key:

  • Names of binary values under this key must be no longer than 3 characters each.

  • You must set the value of HKEY_LOCAL_MACHINE\Comm\< Adapter Name> \Parms\Tcpip\EnableDHCPto 1. If you fail to do so and set the DhcpSendOptions entry, your Windows Embedded CE-based device could experience connection failure.

    Note:
    You are responsible for making sure these options are valid DHCP options and that the stored values are correct. The Windows Embedded CE DHCP client does not format these values; the client only reads these values from the key and appends the values to the DHCP packet.

The following example shows how to encode the host name for sending to the DHCP server. In this example, the host name 12 is set to MyHost:

HKEY_LOCAL_MACHINE\Comm\< Adapter name >\Parms\TcpIp\DhcpSendOptions

@=""

"12"=hex:0c,06,6d,79,68,6f,73,74

See Also