0

i have a service in one application and i want to use that service in one more application.so inoder to start or stop or bind with the service should i need to set any permission?if yes what are the permissions?

Durga
  • 1,191
  • 1
  • 12
  • 18

2 Answers2

0

@Durga first of all you have to make one services class for example TestService.java

(1)TestServices.java

now you have to require for permission in menifest.xml

<service
        android:name=".TestService"
        android:enabled="true" />

    <receiver android:name="com.yourpackage.AutoStart" >
        <intent-filter>
            <action android:name="android.intent.action.BOOT_COMPLETED" />
        </intent-filter>
    </receiver>

now you have to call your services in any activity.

in my case i used receiver to start services in when device is first Boot.

Harshid
  • 5,701
  • 4
  • 37
  • 50
0

Kindly check the following url ... Hopefully it will be useful for you

Basic of Android

onkar
  • 4,427
  • 10
  • 52
  • 89
chiranjib
  • 5,288
  • 8
  • 53
  • 82