Android Webview behind proxy

Lately I have been working on Android platform. If you are behind a proxy in your company and working with the simulator here are the steps to get the browser working

Settings -> Wireless Networks ->mobile networks-> access point names->telkila. Now enter the proxy server address and port (which will be 80).

However, if you are working with WebView control in your app then above will not work unless your code has following line in onCreate()


You might want to restart the emulator after this to test your app again.

Comments (4)

  1. Jay says:

    WebView.enablePlatformNotifications() causes my application to crash and have to Force Stop it.   Cant figure out how to get my webview activity to work behind proxy. Let me know if you have anything more to share

  2. Varun Sekhri says:

    Hmm… I have this code running on Android 2.1/2.2 simulator and an Android 2.1 device.

  3. afobo says:

    add this permission

       <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />

  4. Sam says:

    Thanks Buddy!

    webView.enablePlatformNotifications(); Helped me 🙂