Advertisement
Guest User

Untitled

a guest
Jun 1st, 2011
224
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.86 KB | None | 0 0
  1. using System;
  2. using System.IO;
  3. using Aspose.Pdf.Kit;
  4.  
  5. namespace ImportMetadata
  6. {
  7.     class Program
  8.     {
  9.         static void Main(string[] args)
  10.         {
  11.             // set the license file
  12.             License license = new License();
  13.             license.SetLicense("Aspose.Total.lic");
  14.  
  15.             // open the output file stream
  16.             Stream output = File.OpenWrite(@"c:\users\ryan\desktop\lulz.pdf");
  17.  
  18.             // import the bookmarks
  19.             PdfBookmarkEditor bookmarks = new PdfBookmarkEditor();
  20.             bookmarks.BindPdf(@"c:\users\ryan\desktop\what\edit\_FalconStor Software Inc. FY 2010_4-29-2011 9-10-01 AM.pdf");
  21.             bookmarks.ImportBookmarksWithXML(@"c:\users\ryan\desktop\what\edit\bookmarks.xml");
  22.             bookmarks.Save(output);
  23.  
  24.             // close the stream
  25.             output.Close();
  26.         }
  27.     }
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement