Con.getinputstream() Throw Exception In Android Project, How To Fix?
con.getInputStream() throw exception, when the code running on android, but when copy the code to regular java project it is working, The thrown object e contain 'detailMessage = P
Solution 1:
Make sure you get <uses-permission android:name="android.permission.INTERNET"/>
and not <permission android:name="android.permission.INTERNET"/>
! That bit me for an hour...
Solution 2:
adding<uses-permission android:name="android.permission.INTERNET"/>
tag to manifest
will fix the problem.
Thanks to Jems comment.
Post a Comment for "Con.getinputstream() Throw Exception In Android Project, How To Fix?"