Sunday, May 20, 2012 2:08 AM
How to add "Tap and send" in device like IE metrol ?
Tuesday, May 22, 2012 2:07 AMWe should add "tap and send" with setting in manifest file, or by programming ?
Tuesday, May 22, 2012 8:05 PMModerator
I will see if I can find out how IE puts this up there but realize IE (even Metro IE) is really a desktop app so this may not be possible for you. My question back to you is why do you need this to show in the devices charm? You simply register for NFC and it will connect when another NFC (with the proper programming) is close.
Jeff Sanders (MSFT)
- Proposed As Answer by Jeff SandersMicrosoft Employee, Moderator Tuesday, May 22, 2012 8:05 PM
Wednesday, May 23, 2012 1:42 AMModerator
You need to implement the share contract to share a file. The tap and send option will light up automatically when you do so on a system which supports it. You can demonstrate this with the Sharing content source app sample (http://code.msdn.microsoft.com/windowsapps/Sharing-Content-Source-App-d9bffd84 ) with Scenario 4's "Share files".
Wednesday, May 23, 2012 1:46 AM
Well, in factly, if you listen the event "Windows.ApplicationModel.DataTransfer.DataTransferManager.DataRequested", and set URI or StorageItem with the DataPackage when the event trigger, you will see "Tap and send" in device charm bar.
But only URI and StorageItem can work, other format like bitmap, text will not show "Tap and send".
The other problem is, when the receiver get the invitation, It will open IE to open URI or receive the StorageFile by it self, not my App.
Why do you need this to show in the devices charm?
Because My Boss likes it.
Wednesday, July 11, 2012 1:38 AM
You are correct that Tap and Send only supports URIs and StorageItems.
If it is important that only your app be opened on the receive side, you should send content that only your app understands. For instance use a custom URI protocol "mycustomprotocol:blah" and have your app register as the handler for "mycustomprotocol". Or send StorageItems with file extensions only your app is registered for.
That said, you should really consider whether the content you are sending is specific to your app or if it does make sense to let the user decide which app to open the content in. The user should be in control.
- Marked As Answer by NMG1852951 Wednesday, July 11, 2012 1:47 AM