/* Antenna House PDF Tool API V7.0 .NET Interface sample program 概要:フォームデータのXFDFへのエクスポート Copyright 2021 Antenna House,Inc. */ using System; using PdfTkNet; namespace ExportFormDataXFDF { class ExportFormDataXFDF { static void Main(string[] args) { if (args.Length < 2) { Console.WriteLine("usage: ExportFormDataXFDF.exe in-pdf-file out-xfdf-file"); return; } try { using (PtlParamInput input = new PtlParamInput(args[0])) using (PtlParamOutput output = new PtlParamOutput(args[1])) using (PtlPDFDocument doc = new PtlPDFDocument()) { // PDFファイルをロードします。 doc.load(input); doc.exportFormFieldsToXFDF(output); //フォームフィールドデータのXFDF文書へのエクスポート Console.WriteLine("-- 完了 --"); } } catch (PtlException pex) { Console.WriteLine(pex.getErrorCode() + " : " + pex.getErrorMessageJP()); pex.Dispose(); } catch (Exception ex) { Console.WriteLine(ex.Message); } } } }