iOS – Apple provides screenshot detection notification but not providing direct solution for prevention.
Here I found solution for preventing screenshot taking from the UIView. It’s a simple extension of the UIView that allows to hide it from screen-capturing and also from screen recording. The solution uses ability of UITextField to hide a password from capturing.
Usage:
viewSecure.preventScreenshot()
So, when you take screenshot the logic of text field secure entry (password text field) will not allow to take screenshot of that part.
ScrollView Screenshot Prevention
Update: Here is recursive function for preventing screenshot.
Support
If you like then Buy me a coffee ☕️
Conclusion
Let me know if you have any questions, comments, or feedback – contact me on Twitter.
Stay Safe At Home. Learn Something New. Share To The World.
Happy Coding 🙂