problem in service in manifest file

by Honest » Mon, 17 Aug 2009 18:47:29 GMT

Sponsored Links

I have created the one class named MyService which extends Service. it
is in com.saltriver.service package. Now  can some one tell me how i
should specified it in anroidmanfiest.xml file. The following is
content of xml file but it is giving error in <service>. so can some
one tell me what is wrong in it.

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="" ;
    <application android:icon="@drawable/icon" android:label="@string/
        <activity android:name=".ServiceExample"
                <action android:name="android.intent.action.MAIN" />
android:name="android.intent.category.LAUNCHER" />
    <service android:name=".service.MyService"/>



    <uses-sdk android:minSdkVersion="3" />


problem in service in manifest file

by String » Mon, 17 Aug 2009 21:33:30 GMT

 It'd be helpful if you said what error you're getting.

First off, what you've posted isn't valid XML, the service element's
getting closed twice. Take the / out of the opening tag.

Second, if you get an error of "Class .service.MyService does not
exist", try changing your opening service tag to:
<service android:name=".MyService">



Sponsored Links

Other Threads

1. alsa-lib

today i get the master code. when I  compile ALSA, and it says
external/alsa-lib/src/shmarea.c:27:21: error: sys/shm.h: No such file or
what should I do now? now i copy the shm.h from the former version android.
can be ok?


2. Android 1.1_r1 SDK released and launched

Hey developers, today we released the new, 1.1_r1 SDK. This SDK
includes some minor updates that you can read more about on the blog,
. Also, we've launched the new developer site at
which has updated documentation for the 1.1_r1 SDK.

Android Team @ Google

3. download application on google Market

4. Hey Guys =]

5. Adding text to a custom drawable

6. Bluetooth : RFCOMM connection fails while connecting to a headset which is in discoverable mode.

7. Static Variables after Application life cycle