Product: iOS
Product Version: 17.3
Please give a brief summary of your issue: Hide/Show Annotation in Swift
Please describe your issue and provide steps to reproduce it: I’m trying to hide annotation on PDF. Using below code to hide. But its not working
let pageCount = doc.getPageCount()
for pageNumber in 1...pageCount {
if let page = doc.getPage(UInt32(pageNumber)) {
let annotationCount = page.getNumAnnots()
for i in 0..<annotationCount {
let annot = page.getAnnot(UInt32(i))
annot?.setFlag(PTAnnotFlag(rawValue: 1), value: true)
}
documentController.pdfViewCtrl.update(true)
}
}
Please provide a link to a minimal sample where the issue is reproducible: Create annotation on PDF and try to hide the annotations