Reputation: 4001
If I have a class (Activity) and a service like this case, how can I write the service tag in the manifest?
public class TestA extends Activity {
public class TestB extends Service {
}
}
I know if the service is alone (not within an Activity), I can write it this way:
<service android:name="ThePackageName.TestB" ></service>
But in my case I don't know how to write it down.
Upvotes: 0
Views: 726
Reputation: 2393
<service android:name=".FirstService"
android:enabled="true"></service>
Upvotes: 0
Reputation: 29662
Try it this way :
<service android:name="ThePackageName.TestA.TestB" ></service>
Upvotes: 3
Reputation: 24496
Try this -
<activity android:name=".TestA" android:label="Testing"> </activity>
<service android:name="YourPackage.TestA.TestB"/>
Upvotes: 0