At a certain point it was working fine, but now I am getting the following error:
java.lang.NullPointerException: Attempt to read from field 'java.lang.ref.WeakReference anywheresoftware.b4a.BA$SharedProcessBA.activityBA' on a null object reference
I am also getting the same error with the sample project.
1. I was wondering if there is a solution to fix the above problem
you can use this to get a pop-up where they can select the app to share it with
B4X:
Dim i As Intent
i.Initialize(i.ACTION_SEND, "")
i.SetType("text/plain")
i.PutExtra("android.intent.extra.TEXT", "my text")
i.WrapAsIntentChooser("some info text")
StartActivity(i)
Thanks for your reply. I did look into this before and yes it is extremely powerful.
But the difficulty I had with it: is how to check for available options and create a popup with the standard icons as in the solution by suggested Sorex
you can use this to get a pop-up where they can select the app to share it with
B4X:
Dim i As Intent
i.Initialize(i.ACTION_SEND, "")
i.SetType("text/plain")
i.PutExtra("android.intent.extra.TEXT", "my text")
i.WrapAsIntentChooser("some info text")
StartActivity(i)