Tuesday, 16 June 2015

Android restful library -- retrofit



Follow this video, you will know how to do it (it is not english, just ignore what the gay saying, watch what he did will be fine!)

https://www.youtube.com/watch?v=sLWWEkTN_Mg

However, if you simply follow him, you may get this error, if you print out the failure error:

retrofit.RetrofitError: Permission denied (missing INTERNET permission?)



Solution:

Add a line of code into your AndroidManifest.xml:



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







No comments:

Post a comment