How to add manifest permission to an application?

后端 未结 9 1312
甜味超标
甜味超标 2020-11-22 15:46

I am trying to access HTTP link using HttpURLConnection in Android to download a file, but I am getting this warning in LogCat:

9条回答
  •  悲&欢浪女
    2020-11-22 16:37

    If you are using the Eclipse ADT plugin for your development, open AndroidManifest.xml in the Android Manifest Editor (should be the default action for opening AndroidManifest.xml from the project files list).

    Afterwards, select the Permissions tab along the bottom of the editor (Manifest - Application - Permissions - Instrumentation - AndroidManifest.xml), then click Add... a Uses Permission and select the desired permission from the dropdown on the right, or just copy-paste in the necessary one (such as the android.permission.INTERNET permission you required).

提交回复
热议问题