Hi again, Sorry if I am posting too much, but I really need to make this work today. Here it is my manifest file. I have created a service and a receiver to get the NDEF_DISCOVERED intent.
<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.nfcvoicereader" android:versionCode="1" android:versionName="1.0"> <uses-sdk android:minSdkVersion="10" /> <application android:icon="@drawable/icon" android:label="@string/ app_name"> <service android:enabled="true" android:name="MyService"></ service> <receiver android:enabled="true" android:name="com.android.MyIntentReceiver"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> <intent-filter> <action android:name="android.nfc.action.NDEF_DISCOVERED"/ > <data android:mimeType="text/plain" /> <category android:name="android.intent.category.DEFAULT"/> </intent-filter> </receiver> <uses-feature android:name="android.hardware.nfc" android:required="true" /> </application> </manifest> Inside my project there is a receiver class which should get the intent so that I can start the service. public class MyIntentReceiver extends BroadcastReceiver { static final String TAG = "BROADCAST RECEIVER"; @Override public void onReceive(Context _context, Intent _intent) { ..... } } Can someone tell me what I am doing wrong ?? Thanks On 5 abr, 10:01, Zsolt Vasvari <zvasv...@gmail.com> wrote: > An app without a UI is a service. > > On Apr 5, 3:55 pm, Gorka <gork...@gmail.com> wrote: > > > > > > > > > Hi, > > > I want to deploy an application that reads a NFC tag and shows the > > text on the screen with a Toast and reads it using a texttospeach > > class. So, I don´t want to start an activity because I don´t need any > > GUI. Is that possible? > > > I have tried to remove the activity tags from the manifest but that > > way the application doesn´t work. Is it possible to set the HOME view > > within the OnCreate method instead of using R.layout.main ?? If it is > > possible please tell me how to do it because I don´t know how to get > > this view. > > > Thanks a lot. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en