Textextraction also for comments
Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
-
- User
- Posts: 213
- Joined: Tue Feb 01, 2011 8:14 am
Textextraction also for comments
Hi,
is it possible get the text comment texts using textextraction?
Best regards
cew
is it possible get the text comment texts using textextraction?
Best regards
cew
-
- Site Admin
- Posts: 2445
- Joined: Thu Jun 30, 2005 4:11 pm
Re: Textextraction also for comments
It's possible, by Java-Scripts..
PDF-XChange Co. LTD (Project Developer)
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
-
- User
- Posts: 213
- Joined: Tue Feb 01, 2011 8:14 am
Re: Textextraction also for comments
Are there any c# examples how to do this using JS?Vasyl-Tracker Dev Team wrote:It's possible, by Java-Scripts..
I think for executing JS it is necessary that the document is loaded in the viewer, right?
How do I get the annotation texts just like using text extraction without any UI?
Best
cew
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Textextraction also for comments
Hello Cew,
In the Viewer SDK Installation folder
(by default: C:\Program Files\Tracker Software\PDF-XChange Viewer SDK\Examples\C#Examples )
There is a JavaScript folder - which will show you how to execute JS code inside our Viewer AX.
Unfortunately this will require loading the file indeed - you can still perform the JS without user intervention, but you will need to load the file.
Best,
Stefan
In the Viewer SDK Installation folder
(by default: C:\Program Files\Tracker Software\PDF-XChange Viewer SDK\Examples\C#Examples )
There is a JavaScript folder - which will show you how to execute JS code inside our Viewer AX.
Unfortunately this will require loading the file indeed - you can still perform the JS without user intervention, but you will need to load the file.
Best,
Stefan
-
- User
- Posts: 213
- Joined: Tue Feb 01, 2011 8:14 am
Re: Textextraction also for comments
No way to extract the texts without UI?Tracker Supp-Stefan wrote:Hello Cew,
Unfortunately this will require loading the file indeed - you can still perform the JS without user intervention, but you will need to load the file.

Best,
cew
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Textextraction also for comments
Hello cew,
You could have our Viewer AX sized to 1 by 1 pixel, but you will need to have it inside your application, and load a document before you can execute JS on it. So yes - UI will be needed - even if there is no interaction needed by the user
Best,
Stefan
You could have our Viewer AX sized to 1 by 1 pixel, but you will need to have it inside your application, and load a document before you can execute JS on it. So yes - UI will be needed - even if there is no interaction needed by the user

Best,
Stefan
-
- Site Admin
- Posts: 2445
- Joined: Thu Jun 30, 2005 4:11 pm
Re: Textextraction also for comments
You may use hidden control also...No way to extract the texts without UI?
PDF-XChange Co. LTD (Project Developer)
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
-
- User
- Posts: 213
- Joined: Tue Feb 01, 2011 8:14 am
Re: Textextraction also for comments
No UI means the use of a method like PXCp_ReadDocumentW.
In the extraction scenario is not active (visible or hidden) viewer available.
Best
cew
In the extraction scenario is not active (visible or hidden) viewer available.
Best
cew
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Textextraction also for comments
Hello Cew,
I am afraid that the answer from our devs is that there is no way to extract comments using xcpro (i.e. without UI).
Best,
Stefan
I am afraid that the answer from our devs is that there is no way to extract comments using xcpro (i.e. without UI).
Best,
Stefan
-
- User
- Posts: 213
- Joined: Tue Feb 01, 2011 8:14 am
Re: Textextraction also for comments
I'm afraid too
What about V3?
Best
cew

What about V3?
Best
cew
-
- Site Admin
- Posts: 5223
- Joined: Tue Jun 29, 2004 10:34 am
Re: Textextraction also for comments
It will be possible in V3 - but for sure you will need to enumurate the comments and retrieve the text for each comment found on the page to proceed - for example here is some simple Pseudo code which gives an idea of what it 'should' look like ....
yes, but for sure developer will need to enumerate comment in the document and get text from each of found comments;
pseudo code will be
Hope that helps
yes, but for sure developer will need to enumerate comment in the document and get text from each of found comments;
pseudo code will be
Code: Select all
CComPtr<IPXC_Page> page;
foreach(page in document)
{
CComPtr<IPXC_Annotation> comment;
foreach (comment in page)
{
CComBSTR text = comment->Context;
}
}
If posting files to this forum - you must archive the files to a ZIP, RAR or 7z file or they will not be uploaded - thank you.
Best regards
Tracker Support
http://www.tracker-software.com
Best regards
Tracker Support
http://www.tracker-software.com
-
- User
- Posts: 213
- Joined: Tue Feb 01, 2011 8:14 am
Re: Textextraction also for comments
Great, hope V3 will be released soon
Thank you
Best regards,
cew

Thank you
Best regards,
cew
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Textextraction also for comments
We are hard working on it cew! 
Best,
Stefan

Best,
Stefan