Example #1
0
 protected override void OnShareTargetActivated(ShareTargetActivatedEventArgs args)
 {
     var view = new ShareTarget();
     view.ShareOperation = args.ShareOperation;
     GetTextFromShare(view, args);
     Window.Current.Content = view;
     Window.Current.Activate();
     base.OnShareTargetActivated(args);
 }
Example #2
0
 async void GetTextFromShare(ShareTarget target, ShareTargetActivatedEventArgs args)
 {
     if (args.ShareOperation.Data.Contains(StandardDataFormats.Text))
     {
         var text = await args.ShareOperation.Data.GetTextAsync();
         target.Title = text;
     }
 }