-
Book Overview & Buying
-
Table Of Contents
Near Field Communication with Android Cookbook
By :
Until now, we probably used and reused the same tags to write different content types during the implementation of recipes. There is absolutely no problem with that while we are in the development stage since we need to constantly test what we are doing. In real-life usage, we may need/want to prevent tag rewrites to prevent malicious users from changing the tag content.
We will make some changes in the NfcHelper class and allow the user to choose whether or not to make the tag read-only:
Open Eclipse and create a new Android application project named NfcBookCh10Example3 and the package named nfcbook.ch10.example3.
Make sure the AndroidManifest.xml file is configured correctly. Refer to the Requesting NFC permissions recipe in Chapter 1, Getting Started with NFC.
Set the minimum SDK version to 16 using the following code:
<uses-sdk android:minSdkVersion="16" />
Add the strings given in the following code to the strings.xml file located at res/values/:
<string...
Change the font size
Change margin width
Change background colour