dim cc As ContentChooser
cc.Initialize("cc")
cc.Show("application/pdf", "Choose pdf")
....
Sub cc_Result (Success As Boolean, Dir As String, filename As String)
If Success=True Then
If File.Exists(Starter.Provider.SharedFolder,"file.pdf") Then File.Delete (Starter.Provider.SharedFolder,"file.pdf")
Dim jo As JavaObject
Dim cd As String = jo.InitializeStatic("anywheresoftware.b4a.objects.streams.File").GetField("ContentDir")
Dim in As InputStream = File.OpenInput(cd, filename)
Dim out As OutputStream = File.OpenOutput(Starter.Provider.SharedFolder,"file.pdf", False)
File.Copy2(in,out)
out.Close
If File.Exists(Starter.Provider.SharedFolder,"file.pdf") Then
....
End If
End If
end sub