Get status information of annotation

PDF-XChange Editor SDK for Developers

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

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
Post Reply
lidds
User
Posts: 510
Joined: Sat May 16, 2009 1:55 pm

Get status information of annotation

Post by lidds »

How can I get the status information of an annotation element e.g. status (None, Completed etc.), name of person who applied status change and date of status change (if possible)

I am using the below code to loop through annotation elements, however I cannot see the status attribute in the mData variable?

Code: Select all

        Dim pSInt As PDFXEdit.IPXS_Inst = DirectCast(Me.docPreview.Inst.GetExtension("PXS"), PDFXEdit.IPXS_Inst)
        Dim nID As Integer = Me.docPreview.Inst.Str2ID("op.annots.setProps", False)

        Dim page As PDFXEdit.IPXC_Page = Me.docPreview.Doc.CoreDoc.Pages(0)
        Dim nPageCount As UInteger = page.GetAnnotsCount()

        For i As UInteger = 0 To nPageCount - 1
            Dim annot As PDFXEdit.IPXC_Annotation = page.GetAnnot(i)

            If annot.IsMarkup Then
                Dim data As PDFXEdit.IPXC_AnnotData = annot.Data
                Dim mData As PDFXEdit.IPXC_AnnotData_Markup = DirectCast(data, PDFXEdit.IPXC_AnnotData_Markup)
            End If
        Next
Thanks Simon
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Get status information of annotation

Post by Sasha - Tracker Dev Team »

Hello Simon,

You can try using the JS for this one:
https://forum.pdf-xchange.com/ ... us#p113527

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
lidds
User
Posts: 510
Joined: Sat May 16, 2009 1:55 pm

Re: Get status information of annotation

Post by lidds »

Thanks Alex,

I did see this post but was hoping that this can be achieved using C# or VB.Net as I wanted to loop through the annotation elements and then pass attributes into a stored procedure to insert into a database.

Can this be done in C# or VB.Net?

Thanks

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

Re: Get status information of annotation

Post by Sasha - Tracker Dev Team »

Hello Simon,

Yes, the ExecuteJS method returns the pResult that you can use to gather the needed data.

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
lidds
User
Posts: 510
Joined: Sat May 16, 2009 1:55 pm

Re: Get status information of annotation

Post by lidds »

Thanks Alex,

Got this all working now. Thanks for your help.

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

Re: Get status information of annotation

Post by Sasha - Tracker Dev Team »

:)
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Post Reply