2012-10-11 36 views
2

全部開始Rhomobile的應用,對NFC輕拍

只使用代碼有沒有什麼辦法來啓動應用程序時perticular NFC已經被挖?

我已經看到一些Andriodmanifest.xml的變化,但不是迄今爲止運氣。

以下是我在清單中完成的更改。

<intent-filter> 

<action android:name="android.nfc.action.NDEF_DISCOVERED"/> 

<category android:name="android.intent.category.DEFAULT"/> 

<data android:host="example.com" android:scheme="http" /> 

</intent-filter> 

其中NFC標籤具有example.com存儲的位置。

感謝您的幫助提前。

問候,

阿米特

+0

什麼是存儲在NFC標籤中的* exact *內容? –

回答

1

由於NFC蓋伊。我想通了。 這是

  <intent-filter> 
      <action android:name="android.nfc.action.NDEF_DISCOVERED"/> 
      <data android:scheme="http" 
       android:host="www.example.com" 
       android:path="" /> 
      <category android:name="android.intent.category.DEFAULT"/> 
     </intent-filter>