1

I've tried the solution posted here How to configure a static IP address, netmask, gateway, DNS programmatically on Android 5.x (Lollipop) for Wi-Fi connection but have not been able to get it working.

It compiles and runs fine without crashing, but the IP address stays DHCP and the IP address is not set. Maybe it has to do with the way I am calling test() from another method? To call the test method it asks for an input parameter and the only this I have been able to get it to accept is 'this' so the method call would look like test(this).

Any help would be greatly appreciated.

EDIT: I could be this part of the example that I screwed up:

WifiConfiguration wifiConf = ... /* Get Wifi configuration you want to update */

Does anyone know what the ... should be replaced with?

Community
  • 1
  • 1
Robros
  • 11
  • 4

0 Answers0