Sunday, February 17, 2013 8:27 PMIs there an API function that does the same as "netsh interface ipv4 set address <interface> dhcp"?
Sunday, February 17, 2013 11:07 PM
You want the IP Helper API. SetUnicastIpAddressFunction.
Sunday, February 17, 2013 11:34 PMI think you mean SetUnicastIpAddressEntry. However, could you give me a little example of using this function? I've examined it before, but I couldn't get how to do it. As I can see it takes Address and OnLinkPrefixLength, which together form a concrete IP address. So it's suitable to give an interface a known IP, but what should I do with MIB_UNICASTIPADDRESS_ROW members to command an interface to get an IP from a DHCP?
Monday, February 18, 2013 8:26 AM
Based on your description, I’d like to move this thread to a more appropriate forum: Windows Desktop SDK.
Thanks for your understanding.
MSDN Community Support | Feedback to us
Develop and promote your apps in Windows Store
Please remember to mark the replies as answers if they help and unmark them if they provide no help.