Share contents using certain Apache Cordova plugin


Paolo Lops

Hi David,

there is a way to call android intents?

regards Paolo


DecSoft

Hello Paolo,

Probably we need to use a Cordova plugin, however, can you explain a little more what you wanted to do?



Paolo Lops
I'm studing.... i have see this http://ngcordova.com/docs/plugins/socialSharing/ but i dont know how use it in AB after installing ... in b4a i can use this: https://developer.android.com/training/sharing/send

DecSoft

Hello Paolo,

There is not an easy way to use the "ngCordova" plugin that you refer, because they require certain dependencies that we can't provide, at least right now. However, in fact, that plugin uses this Cordova plugin:

https://github.com/EddyVerbruggen/SocialSharing-PhoneGap-Plugin

And there is no problem to use that plugin from our AB apps, just in the same way (using the plugin's Javascript API) than any other Cordova plugin, as we can see in various AB samples like "CordovaPlugins", "SendSMS" and others.

Please, Paolo, read the documentation of the Cordova plugin that I linked above, try it, and, if you find some specific problem or need more help, just post it here.



Paolo Lops
ok. i try.. tanks.

DecSoft

Hello Paolo,

A couple of things... here is a sample of use of the mentioned Cordova plugin: do not explore all the Javascript API, but, you can read the documentation in order to do what you wanted: the sample prove that, as expected, we can use the plugin in our apps.

https://www.decsoftutils.com/_support/uploads/cordova-plugin-x-socialsharing.zip

On the other hand, maybe you want to try the "Share1" and "Share2" app samples, which use certain existing AB control and don't use any Cordova plugin (this means that the feature can work in all browsers, not only in Cordova compiled apps). You can decide what to use, of course. :-)



Paolo Lops
David, this i what i have need. with this plugin i can share all kinds of files stored locally on my phone or on remote server with no problem. thanks

DecSoft

Hello Paolo,

I think that one of the abilities of that plugin is what you wanted. So you finally get it working? Please, post here if you need any specific help and we will try to help you.


Everybody can read the DecSoft support forum for learning purposes, however only DecSoft customers can post new threads. Purchase one or more licenses of some DecSoft products in order to give this and other benefits.

This website uses some useful cookies to store your preferences.

I agree. Hide this note. Give me more information.