PXC_AddOutlineEntryA always returns null

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: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Stefan - PDF-XChange

ofercomay
User
Posts: 3
Joined: Thu Dec 27, 2007 6:21 pm

PXC_AddOutlineEntryA always returns null

Post by ofercomay »

I'm calling the following line:
PXC_AddOutlineEntryA (hPDF, OutlineItem_Root, OutlineItem_Last, False, 0, szBMTitle, Dest_Page, 0, 0, 0, 0, 0, 0);
and it always returns NULL.
Also, when i call
PXC_SetPageMode (hPDF, PageMode_Outlines);
I receive error code 256.
Anyone knows what the problem is? Thank you!
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: PXC_AddOutlineEntryA always returns null

Post by Stefan - PDF-XChange »

Hello ofercomay,

You are using the ASCII varian of this function and maybe you need to use the UNICODE one?
PXC_AddOutlineEntryW.

Also if you are working with already existing documents why don't you try the
PXCp_BMxxx set of functions?

Best,
Stefan
ofercomay
User
Posts: 3
Joined: Thu Dec 27, 2007 6:21 pm

Re: PXC_AddOutlineEntryA always returns null

Post by ofercomay »

Thank you Stefan. I tried both the unicode and ansi versions of the function - both return the same. By the way - the content of the title is "Page 1".

What do you mean by the PXCp_BMxxx set of functions? Can you tell me about one such function? (sorry but I don't see even one function in my SDK that fits to this pattern...)
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: PXC_AddOutlineEntryA always returns null

Post by Stefan - PDF-XChange »

I had in mind the XCPRO40 LIB Functions

like PXCp_BMInsertItem

They are all documented in the Tools SDK manual

Best,
Stefan
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: PXC_AddOutlineEntryA always returns null

Post by Stefan - PDF-XChange »

Our developers have asked if you could provide a small sample code that can illustrate your problem, and about
PXC_SetPageMode - 256 is not an error but a return code.

Best,
Stefan
ofercomay
User
Posts: 3
Joined: Thu Dec 27, 2007 6:21 pm

Re: PXC_AddOutlineEntryA always returns null

Post by ofercomay »

I looked into this set of functions (PXCp_*). Until now I used the PXC_ functions and what I need is a bookmark in order to jump into a certain page number - something that PXC_AddOutlineEntry should enable. However, the PXCp_ functions look different - they probably allow more and I guess that I cannot mix functions from PXC_ set with PXCp_ set.

Is it possible that the reason that I get NULL for any call to PXCAddOutlineEntryA is that I don't have the full permissions to use this functionality? I bought your SDK in December 2007 (version 3).

Thanks again.
User avatar
John - Tracker Supp
Site Admin
Posts: 5223
Joined: Tue Jun 29, 2004 10:34 am

Re: PXC_AddOutlineEntryA always returns null

Post by John - Tracker Supp »

Permissions would not be the cause - if you have a PDF-Tools SDK license all bookmark options are available to you as are in the SDK - the only 'potentially' excluded functionality is that limited by the author of a PDF file - if Document modification is not allowed and functionality relating to Digi Sigs and Acroforms require a full PDF-XChange PRO SDK license - as do the low level functions - but it is highly unlikely you would be using those anyway.

You are right in that you cannot in V3/V4 mix the use of XCPRO and pxclib library function calls - the former are for use in existing PDF files and the later when creating new files exclusively.

Also - I note you are using V3 and this forum is for V4 of our products - so there may be some inconsistency in regards the code/advice you receive as it will relate to V4 if you post here.

Hope that helps
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