Return-Path: X-Original-To: apmail-pdfbox-users-archive@www.apache.org Delivered-To: apmail-pdfbox-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1191018C10 for ; Tue, 13 Oct 2015 08:52:19 +0000 (UTC) Received: (qmail 47803 invoked by uid 500); 13 Oct 2015 08:51:44 -0000 Delivered-To: apmail-pdfbox-users-archive@pdfbox.apache.org Received: (qmail 47784 invoked by uid 500); 13 Oct 2015 08:51:44 -0000 Mailing-List: contact users-help@pdfbox.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@pdfbox.apache.org Delivered-To: mailing list users@pdfbox.apache.org Delivered-To: moderator for users@pdfbox.apache.org Received: (qmail 11122 invoked by uid 99); 13 Oct 2015 08:06:50 -0000 X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 3.99 X-Spam-Level: *** X-Spam-Status: No, score=3.99 tagged_above=-999 required=6.31 tests=[HTML_MESSAGE=3, KAM_LAZY_DOMAIN_SECURITY=1, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled X-IronPort-AV: E=Sophos;i="5.17,677,1437429600"; d="scan'208,217";a="5064544" From: =?iso-8859-1?Q?Fossest=F8l=2C_Vegard?= To: "users@pdfbox.apache.org" Subject: Problem with pdfbox save(Version 1.8.7 and snapshot 2.0.0) Thread-Topic: Problem with pdfbox save(Version 1.8.7 and snapshot 2.0.0) Thread-Index: AdEFjTkwUH2y584aSnebD8Ma7zZXVw== Date: Tue, 13 Oct 2015 08:06:39 +0000 Message-ID: <1536EF6D5E122641A5B2046088A546DE1197DD8D@no000010sexc31> Accept-Language: nb-NO, en-US Content-Language: nb-NO X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.111.3.64] x-tm-as-product-ver: SMEX-11.0.0.1284-8.000.1202-21876.005 x-tm-as-result: No--43.123500-8.000000-31 x-tm-as-user-approved-sender: No x-tm-as-user-blocked-sender: No Content-Type: multipart/alternative; boundary="_000_1536EF6D5E122641A5B2046088A546DE1197DD8Dno000010sexc31_" MIME-Version: 1.0 --_000_1536EF6D5E122641A5B2046088A546DE1197DD8Dno000010sexc31_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi, I have encountered a strange problem with pdf box. I'm trying to split a La= rger PDF file into smaller ones. The split function does work, but when sav= ing the new generated pdf to disk, there's a problem. I get this errormessa= ge: COSStream has been closed and cannot be read. Perhaps its enclosing PDDocum= ent has been closed? But I've sysout'ed the state of the document which say's it's not closed. A= nd as well, the program runs properly in debug mode. I'm currently running = eclipse on a Websphere applicatation Server 7. And I've tried to fix the pr= oblem for days now. But converting the PDDocument to a bytearray, and every= thing that is possible. As well I've tried to just use your save function t= hat takes a filename as a parameter (Which is extremely slow, you should us= e a filebuffer and bytearray to save it). Hope you have the time to help me as soon as possible. Btw, get the same er= ror at version 1.8.7 and 2.0.0 Med vennlig hilsen Vegard Fossest=F8l Tlf: 916 32 699 Konsulent M=F8llergruppen --_000_1536EF6D5E122641A5B2046088A546DE1197DD8Dno000010sexc31_--