iOS Question Trying to implement DocumentPickerViewController

MitchBu

Well-Known Member
Licensed User
I am trying to wrap my head around https://www.b4x.com/android/forum/t...ents-with-documentpickerviewcontroller.99365/

I am puzzled with Page 1 and Button1. Should I prepare a page in Designer containing these items ?

I don't see these items in the posted picture.

Since there is no example project, I am in the dark.

Will appreciate help. TIA.

B4X:
Sub Page1_Click
   DocumentPicker.InitializeImport("picker", Array("public.image"))
   DocumentPicker.Show(Page1, Button1)
   Wait For Picker_Complete (Success As Boolean, URLs As List)
   If Success Then
       ImageView1.Bitmap = LoadBitmap(URLs.Get(0), "")
   End If
End Sub
 

Erel

Administrator
Staff member
Licensed User
Should I prepare a page in Designer containing these items ?
No.

Page1 should be replaced with the current page. If you are using B4XPages (you should) then you need to get the native page with B4XPages.GetNativeParent(Me).

Button1 should be any view that this dialog will be anchored to on iPads.
 
Upvote 0
Top