I adapt, 1 1/2 year ago, a QR code reader application from the example found in the forum. Now i want to be able read a business card containg a QR code in vcf file mode. I found an example at https://www.b4x.com/android/forum/threads/insert-a-new-contact-with-a-qrcode-vcard.147894/. QR Code has been successfuly read and save to file in “fp.SharedFolder”, I believe. I get an abend in “fp.GetFileUri”. Maybe the problem is coming from the permissions I don’t give. No Manifest file example has been given in the example. Which permissions should I give in manifest file ?
B4X:
Dim fp As FileProvider
fp.Initialize
File.WriteString(fp.SharedFolder, "vcard.vcf", s)
Log("File vcard has been created...")
'Insert in contacts
Dim thisintent As Intent
thisintent.Initialize(thisintent.ACTION_VIEW,fp.GetFileUri(fp.SharedFolder & "/vcard.vcf"))
thisintent.SetType("text/x-vcard")
thisintent.Flags = 0x01
StartActivity(thisintent)