RFID Reader Interface User's Guide
2.2 How Do I Use the Reader Interface?
2.2.7
Change the Tags' Data
When the data on a tag must be changed, the same restriction applies on EPC Gen2 tags as
with obtaining additional data. The EPC Gen2 tag that you want to change must be specified
by supplying its ID. Only if a matching tag is detected will the operation succeed.
How to write a new ID to an existing tag for a data-change function (for EPC GEN2 only):
The tag's current ID must be supplied together with the new ID and a password (if needed)
and an instance of an object must be used that implements the IRfReaderApi which is
always available via RfReaderApi.Current.
Figure 2-6
Below is the code for accomplishing this; writing a new tag ID to a tag:
try
{
}
catch (RfReaderApiException rfidException)
{
}
20
Write TagID
// Code for invoking a dialog and retrieving the data entered
left out for brevity -> check sample code for details
...
// Request all tags that are currently within reach
RfReaderApi.Current.SetTagID(
currentTagID, newTagID,
accessPassword);
// Something went wrong while writing data
AddInformation(string.Format("ERROR: {0} - {1}, cause: {2},
desc: {3}\r\n",
rfidException.ResultCode, rfidException.Error,
rfidException.Cause, rfidException.Description));
Function Manual, 02/2009, J31069-D0198-U001-A1-0076
Mobile Reader