android - Can not resolve org.apache.http.entity.mime.MultipartEntity , HttpMultipartMode -
snapshot of android studio screen
snapshot of error messages inside android studio
i followed suggestions mentioned here not resolve errors.how add external dependencies (jar file) android studio?
please suggest missing here?
1:
1:
1) add line android tag of build.gradle file
uselibrary 'org.apache.http.legacy'
it after adding line :
android { compilesdkversion 23 buildtoolsversion "23.0.2" uselibrary 'org.apache.http.legacy'
please check link know why need add : https://developer.android.com/about/versions/marshmallow/android-6.0-changes.html#behavior-apache-http-client
2) if have downloaded jar skip step, have seen in screenshot have added build.gradle file.
download file , extract jar it. http://www.java2s.com/code/jardownload/httpmime/httpmime-4.1.1.jar.zip
and add library library folder. right click on jar file , click on option "add library..."
this should work
Comments
Post a Comment