So I have a page in my app where I want to to hide some content when users take a screenshot.
I tried to observe UIApplication.userDidTakeScreenshotNotification
but it only notifies the observer after the screenshot is taken.
I also tried to override touchesCancelled
but it also didn't work.
Asked
Active
Viewed 1,720 times
0

Ahmad Ismail
- 641
- 7
- 15
-
7Quick searching will tell you that you ***cannot*** prevent screenshots on iOS. Even if you could, what's to stop someone grabbing another phone and taking a photo? – DonMag Mar 04 '21 at 21:02
-
but we can forcefully delete the screenshot after detecting it without knowing the user https://stackoverflow.com/questions/56731764/observe-and-delete-screenshot-if-a-screenshot-is-taken-while-using-my-app-in – Adarsh KC Mar 05 '21 at 06:56
-
1@Adarsh If you would implement something like this - deleting the latest photo - I would immediatly delete your app from my device – Andreas Oetjen Mar 05 '21 at 07:57
-
Does this answer your question? [Is it possible and legal to disable home button and the screenshot feature in an ipad app?](https://stackoverflow.com/questions/17557701/is-it-possible-and-legal-to-disable-home-button-and-the-screenshot-feature-in-an) – Andreas Oetjen Mar 05 '21 at 08:11