- Posts: 16
- Thank you received: 0
Microsoft Windows Phone 8.1 support ends (13 Jul 2017)
Microsoft has ended support for Windows Phone 8.1
Questions about Android development and PDF
Which page have annotation or not
IP: 192.168.0.71
12 years 1 month ago #6875
by Mahesh007
Which page have annotation or not was created by Mahesh007
i want to know which page isannoted in PDFDoc.please help on this.
IP: 192.168.0.156
12 years 1 month ago #6876
by Davide
Replied by Davide on topic Which page have annotation or not
Hi,
try this to get page annot count:
and then check if numberOfAnnot > 0
try this to get page annot count:
Code:
Page myPage = m_doc.GetPage(pageno);
int numberOfAnnot = myPage.GetAnnotCount();
and then check if numberOfAnnot > 0
IP: 192.168.0.71
12 years 1 month ago #6910
by Mahesh007
Replied by Mahesh007 on topic Which page have annotation or not
pagecount is working but page annotation count always give me value 0 . please help on this
PDF_ERR err = 0;
m_doc = [[PDFDoc alloc] init];
err = [m_doc open:pdfPath :@""];
if( m_doc == NULL )
{
switch( err )
{
case err_password:
NSLog(@"Error %d",2);
break;
default:
NSLog(@"Error %d",0);
}
}
NSLog(@"no of page in doc %d",m_doc.pageCount);
PDFPage *page = [m_doc page:0];
NSLog(@"annotate %d",page.annotCount)
PDFPage *page1 = [m_doc page:1];
NSLog(@"annotate %d",page1.annotCount);
PDF_ERR err = 0;
m_doc = [[PDFDoc alloc] init];
err = [m_doc open:pdfPath :@""];
if( m_doc == NULL )
{
switch( err )
{
case err_password:
NSLog(@"Error %d",2);
break;
default:
NSLog(@"Error %d",0);
}
}
NSLog(@"no of page in doc %d",m_doc.pageCount);
PDFPage *page = [m_doc page:0];
NSLog(@"annotate %d",page.annotCount)
PDFPage *page1 = [m_doc page:1];
NSLog(@"annotate %d",page1.annotCount);
IP: 192.168.0.71
12 years 1 month ago - 12 years 1 month ago #6917
by radaee
Replied by radaee on topic Which page have annotation or not
like this:
Page page = doc.GetPage(pageNO);
page.ObjsStart();//it is required.
int annot_count = page.getAnnotCount();
//...
page.Close();
Page page = doc.GetPage(pageNO);
page.ObjsStart();//it is required.
int annot_count = page.getAnnotCount();
//...
page.Close();
Last edit: 12 years 1 month ago by .
Time to create page: 0.560 seconds