I was recently asked via an e-mail from a user of my Lanscan app how to obtain DHCP information from a Windows Store app.
Fortunately, DhcpRequestParams and related Win32 APIs are part of the Windows Store partition of the Win32 API and so are callable from C#-based Windows Store apps (and probably other places too).
Here are Gists of the relevant p/invoke and interop declarations you’ll need in order to call these functions from your C# programs:
DHCPCAPI_IP_ADDRESS: DHCPCAPI_PARAMS: DHCPCAPI_PARAMS_ARRAY: DHCPCAPI_REQUEST: OPTION: Content © 2025 Richard Cook. All rights reserved.