All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE

All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE - Welcome to ANDROID KAWE, Ini adalah sebuah blog directory tentang burung,baik itu suara burung ataupun tips perawatan burung.Blog ini adalah situs perangkum otomatis dari pencarian google yang kali ini berjudul All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE.Ada ribuan artikel yang sudah terekam ke dalam situs ini,silahkan cari sesuai yang kalian kehendaki,untuk artikel selanjutnya tentang judul diatas bisa kalian baca di bawah ini.

Konten : All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE
Judul : All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE

lihat juga


All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE


Exception networkonmainthreadexception in Android



This exception is due to the StrictMode introduced on honeycomb or later android devices to not allow the network operations in main thread.


The solution to this exception is that you implement a thread for network operation instead of implementing in main thread.


The alternative method is to disable the option which is enable by default in honeycomb and later android OS.The previous versions of android OS allowed the main thread to create the network connections.


Disabling the StrictMode in Android


StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();
StrictMode.setThreadPolicy(policy);


If you like the solution please provide your comments.


Thanks
Creative Android Apps


Demikianlah Artikel All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE

Semoga artikel tentang All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE, mudah-mudahan bisa memberi manfaat untuk anda semua.

Anda sedang membaca artikel All About Android-Exception networkonmainthreadexception in Android-ANDROIDKAWE dan artikel ini url permalinknya adalah http://androidkawe.blogspot.com/2012/07/all-about-android-exception.html Semoga artikel ini bisa bermanfaat.Sekali lagi,ini adalah situs auto yang tidak ditulis langsung oleh admin,Kami tidak menjamin akan kebenaran dari artikel yang tertulis.
Back To Top