How to extract comments without exporting file and UI

This Forum is for the use of Software Developers requiring help and assistance for Tracker Software's PDF-Tools SDK of Library DLL functions(only) - Please use the PDF-XChange Drivers API SDK Forum for assistance with all PDF Print Driver related topics or PDF-XChange Viewer SDK if appropriate.

Moderators: Tracker Support, TrackerSupp-Daniel, Chris - Tracker Supp, Vasyl-Tracker Dev Team, Sean - Tracker, Tracker Supp-Stefan

Post Reply
crimsonlogic
User
Posts: 38
Joined: Tue Jan 12, 2016 2:25 am

How to extract comments without exporting file and UI

Post by crimsonlogic » Thu Jul 07, 2016 10:00 am

Hi Tracker Team,

Currently, I'm using DoVerb with "SummarizeAnnots" to get comments summary.
But it will create a physical file and have to load pdf in viewer.

I'm doing a simple search engine for searching both content and comments, is there any way that can extract comment page by page like extract normal content?

User avatar
Tracker Supp-Stefan
Site Admin
Posts: 13320
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: How to extract comments without exporting file and UI

Post by Tracker Supp-Stefan » Thu Jul 07, 2016 10:46 am

Hello Crimsonlogic,

Our PDF Tools SDK is a bit older and might not have all the features you need. Is it an option for you to use the Core API instead? I am confident it will be faster and easier to achieve this with the Core API than with the Tools SDK (if at all possible with Tools).

You can download and give the Core API a try here:
https://www.tracker-software.com/produc ... re-api-sdk

Regards,
Stefan

crimsonlogic
User
Posts: 38
Joined: Tue Jan 12, 2016 2:25 am

Re: How to extract comments without exporting file and UI

Post by crimsonlogic » Fri Jul 08, 2016 3:02 am

Thanks for your information.
Is there any C# example for getting annotation page by page with PDFXCoreAPI?

User avatar
Sasha - Tracker Dev Team
User
Posts: 4076
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: How to extract comments without exporting file and UI

Post by Sasha - Tracker Dev Team » Fri Jul 08, 2016 2:07 pm

Hello crisonlogic,

Well, you can get the required annotation properties from the IPXC_Annotation interface:
http://sdkhelp.tracker-software.com/vie ... Annotation
You can get all of the page's annotations by using
http://sdkhelp.tracker-software.com/vie ... e_GetAnnot
http://sdkhelp.tracker-software.com/vie ... nnotsCount

Cheers,
Alex
Join us at Google+:
https://plus.google.com/+PDFXChangeEditorTS
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ

crimsonlogic
User
Posts: 38
Joined: Tue Jan 12, 2016 2:25 am

Re: How to extract comments without exporting file and UI

Post by crimsonlogic » Mon Jul 11, 2016 2:04 am

According to the document, IPXC_Document is the interface of object of PDF-XChange Editor SDK.
So I have to use PDF-XChange Editor SDK, not only Core API SDK, right?

crimsonlogic
User
Posts: 38
Joined: Tue Jan 12, 2016 2:25 am

Re: How to extract comments without exporting file and UI

Post by crimsonlogic » Mon Jul 11, 2016 6:38 am

I am following this post for my purpose.
http://www.tracker-software.com/forum3/ ... ge#p101345

According document http://sdkhelp.tracker-software.com/view/PXV:IPXC_Pages
I can get correct Count property, but when I try to use pages.Item, will get build error.

Any suggestion?

crimsonlogic
User
Posts: 38
Joined: Tue Jan 12, 2016 2:25 am

Re: How to extract comments without exporting file and UI

Post by crimsonlogic » Tue Jul 12, 2016 2:43 am

My code:

Code: Select all

PDFXCoreAPI.PXC_Inst g_Inst = new PDFXCoreAPI.PXC_Inst();
            g_Inst.Init(mykey);

            IPXC_Document pDoc =g_Inst.OpenDocumentFromFile(inputfile,null);
            
            IPXC_Pages pages = pDoc.Pages;
var pageCount=pages.Count;
I can get the page count, but how to do next to get annotation of every page?

crimsonlogic
User
Posts: 38
Joined: Tue Jan 12, 2016 2:25 am

Re: How to extract comments without exporting file and UI

Post by crimsonlogic » Tue Jul 12, 2016 3:39 am

Anyway, I got it, thanks

User avatar
Sasha - Tracker Dev Team
User
Posts: 4076
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: How to extract comments without exporting file and UI

Post by Sasha - Tracker Dev Team » Tue Jul 12, 2016 6:21 am

Hello crimsonlogic,

Sorry for the late reply. Glad you found a solution. You can search the Editor SDK or the CoreAPI SDK forums for the keywords you need - right now they contain answers to many questions.

Cheers,
Alex.
Join us at Google+:
https://plus.google.com/+PDFXChangeEditorTS
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ

Post Reply