0 Replies Latest reply on Mar 21, 2010 10:18 PM by gppgraham

    Using Adobe Viewer in C# .NET Application


      We are building a C# .NET Windows .EXE application. One of the features we require is for this application to display PDF files in a popup window.


      I have imported references to our VS 2008 project for AcroPDFLib and added an AxAcroPDFLib.AxAcrosPDF component to a form.

      The following code successfully displays a PDF file:


      axAcroPDF.Visible =



      if(axAcroPDF.LoadFile(spFileName)) {


          MessageBox.Show("Error: PDF Viewer failed to load file '" + spFileName + "' !", "Content Access System", MessageBoxButtons.OK,



      else {


          if(spNamedDest != "") axAcroPDF.setNamedDest(spNamedDest);



      For some reason, the named destination seems to work the first time it is called, but never works again after that - the PDF always scrolls to the destination on the first call.


      What we need to be able to do is to load a PDF file and scroll it to a known bookmark location or named destination - I am aware that the two are different things but I am not clear on that difference.


      Can anyone please suggest how I can reliably scroll to a bookmark and if indeed, AcroPDFLib is the right component for the job ? If it is the right component, we don't seem to be seeing any methods on the object to manipulate it.




      Graham Plowman