// --------------------------------------------------------------------------- public void Write(Stream stream) { using (ZipFile zip = new ZipFile()) { XfaMovie x = new XfaMovie(); zip.AddEntry(RESULTTXT, x.ReadFieldnames(new PdfReader(RESOURCE))); XfaMovies xfa = new XfaMovies(); string xml = xfa.CreateXML(); zip.AddEntry(XMLDATA, xml); zip.AddEntry(RESULT, xfa.ManipulatePdf(RESOURCE, xml)); zip.Save(stream); } }
// --------------------------------------------------------------------------- public void Write(Stream stream) { using (ZipFile zip = new ZipFile()) { XfaMovies xfa = new XfaMovies(); XMLDATA = xfa.CreateXML(); zip.AddEntry(Utility.ResultFileName(xfa.ToString() + ".xml"), XMLDATA); using (MemoryStream ms = new MemoryStream()) { using (document = new Document()) { PdfWriter.GetInstance(document, ms); document.Open(); Parse(document); } zip.AddEntry(Utility.ResultFileName( this.ToString() + ".pdf"), ms.ToArray() ); } zip.Save(stream); } }