Get Annots details
Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
-
- User
- Posts: 108
- Joined: Wed May 13, 2009 2:21 pm
Get Annots details
Hello,
How can I get all details of annotation position (e : Top left (x,y), buttom Down (x,y).....etc) ?
Thank you for help.
How can I get all details of annotation position (e : Top left (x,y), buttom Down (x,y).....etc) ?
Thank you for help.
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Get Annots details
Hi Rad1,
The getProps method gets all the properties for the selected annotation
For the full list of properties an annotation has reffer to adobe's JavaScript for Acrobat API Reference
The getProps method gets all the properties for the selected annotation
For the full list of properties an annotation has reffer to adobe's JavaScript for Acrobat API Reference
-
- User
- Posts: 664
- Joined: Tue Nov 14, 2006 12:23 pm
Re: Get Annots details
Here is small sample of how to get all annots rects via JS:
Code: Select all
var annots=this.getAnnots(0);
if(annots!=null)
{
for(var i=0;i<annots.length;i++)
{
var props=annots[i].getProps();
if (props!=null)
{
var name = props["name"];
console.println("Name:");
console.println(name);
var rectstring;
rectstring = props["rect"];
console.println("Rect:");
console.println(rectstring);
}
}
}
-
- User
- Posts: 108
- Joined: Wed May 13, 2009 2:21 pm
Re: Get Annots details
Hi,
Thank you for your response. I'm using JS to develope my application. How can I get the result of RunJavaScript Function using JS. As you know, Javascript does not support the passing of parameters by reference.
There any other alternative ?
Thank you.
Thank you for your response. I'm using JS to develope my application. How can I get the result of RunJavaScript Function using JS. As you know, Javascript does not support the passing of parameters by reference.
There any other alternative ?
Thank you.
-
- User
- Posts: 664
- Joined: Tue Nov 14, 2006 12:23 pm
Re: Get Annots details
Sorry - for now we don’t have any other method for getting annots coordinates.
-
- User
- Posts: 108
- Joined: Wed May 13, 2009 2:21 pm
Re: Get Annots details
Ok, Hope that will be available for the next builds.
Can I intercept event when I draw a new rectangle (annotation) ?
Can I intercept event when I draw a new rectangle (annotation) ?
-
- User
- Posts: 664
- Joined: Tue Nov 14, 2006 12:23 pm
Re: Get Annots details
No, Viewer ActiveX doesn’t support such events.
-
- User
- Posts: 108
- Joined: Wed May 13, 2009 2:21 pm
Re: Get Annots details
mmmm
I wanted to use the PDF Xchange viewer to get OCR area in the pdf file using annotation as selector. I hope that the ocr librairy will be available as soon as possible. I'm very satisfied with your products.
Thank you.

I wanted to use the PDF Xchange viewer to get OCR area in the pdf file using annotation as selector. I hope that the ocr librairy will be available as soon as possible. I'm very satisfied with your products.
Thank you.
-
- User
- Posts: 664
- Joined: Tue Nov 14, 2006 12:23 pm
Re: Get Annots details
Well, you can get mouse events, such as Mouse Down, Mouse Move and Mouse Up, and cursor position in page coordinates, so you can make your own tool to select some rectangle on page.
-
- User
- Posts: 59
- Joined: Sat May 09, 2009 3:05 pm
Re: Get Annots details
Good day
Is possible small sample how to create own selection procedure?
Thank you Miro
Is possible small sample how to create own selection procedure?
Thank you Miro
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Get Annots details
Hello Miro,
I think that your question is a bit away from the original topic - so a separate one would have been better, but could you please be a bit more specific about what exactly selection you want to do - and at what level - and we should be able to point you in the right direction.
Best,
Stefan
I think that your question is a bit away from the original topic - so a separate one would have been better, but could you please be a bit more specific about what exactly selection you want to do - and at what level - and we should be able to point you in the right direction.
Best,
Stefan
-
- User
- Posts: 59
- Joined: Sat May 09, 2009 3:05 pm
Re: Get Annots details
Hello Stefan,
How to is possible make this functiononality:
How to is possible make this functiononality:
Corwin - Tracker Sup wrote:Well, you can get mouse events, such as Mouse Down, Mouse Move and Mouse Up, and cursor position in page coordinates, so you can make your own tool to select some rectangle on page.
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Get Annots details
Hello miromr,
You can achieve this using JavaScript - and all the cursor coordinate commands and Mouse events you need can be found in the
JavaScript for Acrobat API Reference
Best,
Stefan
You can achieve this using JavaScript - and all the cursor coordinate commands and Mouse events you need can be found in the
JavaScript for Acrobat API Reference
Best,
Stefan
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am