Is there a standard way to generate a QR code and attach it to a mail item from iOS client app (no server code)?
相关问题
- Core Data lightweight migration crashes after App
- How can I implement password recovery in an iPhone
- State preservation and restoration strategies with
- “Zero out” sensitive String data in Swift
- Get the NSRange for the visible text after scroll
相关文章
- 现在使用swift开发ios应用好还是swift?
- UITableView dragging distance with UIRefreshContro
- TCC __TCCAccessRequest_block_invoke
- Where does a host app handle NSExtensionContext#co
- Swift - hide pickerView after value selected
- How do you detect key up / key down events from a
- didBeginContact:(SKPhysicsContact *)contact not in
- Attempt to present UIAlertController on View Contr
Since iOS 7, you can use a Core Image filter to generate QR images. See the final tip here:
Using Swift 2
Swift 3.0
Swift 4.2
For Obj-C version that perfectly works for me, I've mixed answers पवन and Teja Kumar Bethina:
It has been a while since this question was asked and a number of almost perfect answers have been given already. However I had to tweak and combine several answers to get it working perfectly for AppleTV 4K, iPhone X and iPadPro using Xcode 9.2 in 2018. Here's the code if anyone needs it.
First, you need to find a short link service, e.g. bit.ly or goo.by, to make a long link shorter and thus reduce QR Code size.
To perform this task automatically you will have to use some web service.
ZXing is a popular open source QR Code generator also available for iOS
I created a NSString Category for Obj-C, taking Mike Demidov awesome answer
NString+GGQRCode.h
NString+GGQRCode.m