-1

I guess the QR code scanning app can be opened by UIApplication.shared.open(_ url: URL) with the URL scheme of the scanning app. But what is that? Or is there another way to open it?

HangarRash
  • 7,314
  • 5
  • 5
  • 32
Daniel
  • 507
  • 6
  • 22
  • iOS doesn't have a "qr scanning app". There is the camera and there is the code scanner that the user can access via control Center. I don't believe there is any way to open that through code. You can add QR code scanning to your app if you need that feature. – Paulw11 May 29 '23 at 21:25

1 Answers1

0

URL Schemes allow you to launch other apps (usually to handle some content that's addressed). This is not unique to iOS.

For example the 'http' scheme will usually launch a web browser and load the content at the URL; the 'ftp' scheme would launch an FTP application pointing to the host specified in the URL.

Apple allows you define custom URL schemes that your own app can handle. Some 'QR Scanner' applications doubtlessly have defined their own schemes, as documented here. It makes sense that you could find such an app and use the scheme it defines to launch it.

Or use a framework like AVFoundation or VisionKit to do it yourself.

emma ray
  • 13,336
  • 1
  • 24
  • 50