[Question] About Windows Store object again

Discussion and feedback on Construct 2

Post » Tue Dec 06, 2016 9:02 am

Hi all!

In Constrcut2 we can't use Windows Store action Show Share UI for Windows 10 UWP. But I use this method and it work:

1. I create file share.js with code:

Code: Select all
 var dataTransferManager = Windows.ApplicationModel.DataTransfer.DataTransferManager.getForCurrentView();
        dataTransferManager.addEventListener("datarequested", function (e) {
            var request = e.request;
            request.data.properties.title = "Your title";
            request.data.setText("Your text");

2. Import share.js in project.
3. Browser object -> Execute Javascript:

Code: Select all
var js = document.createElement('script');
js.type = 'text/javascript';
js.src = 'share.js';

It work on windows 10 and windows 10 mobile - Share UI is shown and I can choose any social network in which I want to share. Why Windows Store object can't do that?
Posts: 120
Reputation: 1,536

Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 9 guests