attach picture on facebook by sharing menu

Yeshua

Member
Licensed User
Longtime User
I use this code to attach a picture to the email, bluetooth, etc, through the use of the sharing menu.
Often, however, it's not work and I have to use the keyback button to make it reappear.

If in the sharing menu I choose facebook, the image is not attached.

You can do this?

B4X:
Sub Button1 Click

Dim OutM As OutputStream
Dim BitmapM As Bitmap
File.MakeDir(File.DirRootExternal, "/Email")
BitmapM.Initialize(File.DirAssets, "Jolly.jpg")
OutM=File.OpenOutput(File.DirRootExternal & "/Email","Jolly.jpg",False)
BitmapM.WriteToStream(OutM, 100, "JPEG")
OutM.Close

Dim Message As Email
Message.Attachments.Add(File.Combine(File.DirRootExternal & "/Email","Jolly.jpg"))
Message.Subject = "Hello!!"
Message.Body = "Bla,bla,bla"
StartActivity(Message.GetIntent)

End sub
:signOops:
 
Top