I would like the user to be able to choose an existing image and upload it to the FTP server. I tried to use the following code to identify the image:
The code returns as values:
Dir = ContentDir
FileName = content://com.android.providers.media.documents/document/image%3A5216
and obviously the upload is not performed. What should I do so that the user can upload images from anywhere on his device (internal or SD Card)?
I tried to upload an image from a known location and the code works.
Thank you!
B4X:
cc.Initialize("CC")
cc.Show("image/*", "Select image")
Wait For CC_Result (Success As Boolean, Dir As String, FileName As String)
If Success Then
Dim sf As Object = ftp.UploadFile( Dir, FileName, False, FileName)
.........
End If
Dir = ContentDir
FileName = content://com.android.providers.media.documents/document/image%3A5216
and obviously the upload is not performed. What should I do so that the user can upload images from anywhere on his device (internal or SD Card)?
I tried to upload an image from a known location and the code works.
B4X:
Dim sf As Object = ftp.UploadFile( File.DirRootExternal, "test.jpg", False, "test.jpg")
Thank you!