开发者

Android GPS manifest not OK

开发者 https://www.devze.com 2023-02-21 22:38 出处:网络
I am going to implement the GPSinto one of my menu XML , JAVA code is OK but when running this application , I have seen the application has stopped unexpectedly

I am going to implement the GPS into one of my menu

XML , JAVA code is OK

but when running this application , I have seen the application has stopped unexpectedly

here is my Manifest..

<application 
android:icon="@drawable/icon" 
android:label="@string/app_name">

开发者_运维技巧 ....

....

</application>
<uses-sdk android:targetSdkVersion="8" android:minSdkVersion="8"/>
<uses-permission android:name="android.permission.CALL_PHONE"></uses-permission>


You need

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

to access the GPS


    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"></uses-permission>
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"></uses-permission>
<uses-permission android:name="android.permission.ACCESS_MOCK_LOCATION"></uses-permission>
<uses-permission android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" /> 


If you're using GPS, add the permission ACCESS_FINE_LOCATION as well.

0

精彩评论

暂无评论...
验证码 换一张
取 消