Solved

NFC Example for Static Tags in VB.net on Windows Phone 8

Posted on 2013-11-12
3
798 Views
Last Modified: 2014-11-12
As the title says, I'm looking for a NFC example for static tags in VB.net.

I've tried using the vb.net code from

http://msdn.microsoft.com/en-us/library/windows/apps/windows.networking.proximity.proximitydevice.subscribeformessage(v=win.10).aspx

But the SubscribeForMessage event handler never fires ?

Would be great if someone could post some code that works and has been tested with a real world windows phone.
0
Comment
Question by:Dodsworth
3 Comments
 
LVL 1

Accepted Solution

by:
Dodsworth earned 0 total points
ID: 39829801
Error in the example I think.  MessageRecieved needs to be on the UI thread.

 Public Sub MessageReceived(sender As ProximityDevice, message As ProximityMessage)
        Deployment.Current.Dispatcher.BeginInvoke(Sub()
                                                      txtRead.Text = message.DataAsString.Replace(vbNullChar, "")
                                                  End Sub)
    End Sub

Open in new window

0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question