4 Replies Latest reply: Apr 25, 2012 9:05 AM by tyerlv123 RSS

    PDAnnotInfoRec

    tyerlv123 Community Member

      How do I return the Author, Date of an annotation.


      I see this structure PDAnnotInfoRec and it has the author, date as members but how do I fill the structure with data in order to return the members.

       

      It also looks like I need to use: PDAnnotHandlerGetAnnotInfoProc but what do I return? and how do I call or use this callback.  At the same time it says I need to use the AVAnnotGetInfo, and AVAnnotDeleteInfo...what do I have to return or do in those callbacks?

        • 1. Re: PDAnnotInfoRec
          tyerlv123 Community Member

          Correct me where I am wrong:

           

           

          PDAnnotHandlerRec annotHanderRec;

           

          ASAtom atom;

          atom = PDAnnotGetSubtype(annot);

           

          PDAnnotHandler annotHandler;

           

          annotHandler = PDGetAnnotHandlerByName(atom); //is that correct?  Is the subtype the same as Name? If not...how do I set atom? Using what method?

           

          PDAnnotInfo annotInfo = annotHanderRec.GetAnnotInfo(annotHandler, annot, page);  //Goes to the callback

           

          //Callback

          static ACCB1 PDAnnotInfo ACCB2 PDAnnotGetInfoTest(PDAnnotHandler annotHandler, PDAnnot annot, PDPage pdpage){

               PDAnnotInfoRec info;

               info.size = sizeof(PDAnnotInfoRec);

              

               //Now How do I return the information of the info? in order to get the Author, Date etc?

               //If I try this

               AVAlertNot((char *) info.cAuthor); //I get a bad pointer when I debug it.

               return info;

          }

          • 2. Re: PDAnnotInfoRec
            lrosenth Adobe Employee

            No, Subtype is NOT the same as name.  Name is the internal/registered name for the handler.

             

            Your work is at a level where you need to get official/formal support.  Please submit a request via the appropriate channels.

            • 3. Re: PDAnnotInfoRec
              tyerlv123 Community Member

              And where/how do I do that?

               

              Thanks

              • 4. Re: PDAnnotInfoRec
                tyerlv123 Community Member

                Can I ask just one more question in regards to this...is my code aboe the only way to get the Author, Creation date?  Is there another way to do the same without having to invoke the annotHandler?