Android Question Change WiFi Proxy Configuration

amidgeha

Active Member
Licensed User
Longtime User
Is there a way to change and save WiFi proxy on all Android versions?
 

amidgeha

Active Member
Licensed User
Longtime User
There are several wifi related libraries: https://www.b4x.com/android/forum/pages/results/?query=wifi&prefix=1,2,3,17,24,29

I'm not sure whether any of them supports this. You will need to check.

I wrapped this library using its AAR Library but it works only on Lollipop devices
B4X:
    public void changeProxySettings(BA ba, String host, int port) {
        try {            WifiProxyChanger.changeWifiStaticProxySettings(host, port, ba.context);
        } catch (ClassNotFoundException | NoSuchMethodException | InstantiationException
                | InvocationTargetException | NoSuchFieldException | IllegalAccessException |
                NullWifiConfigurationException | ApiNotSupportedException e) {
            e.printStackTrace();
        }
}
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…