You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@poi.apache.org by Leila Homaeian <le...@cs.ualberta.ca> on 2006/08/10 22:36:33 UTC
Get text from a URL pointing to a ppt file
Hello,
I am trying to use SlideShow.getSlides() to get slides from a URL pointing
to a powerpoint file. The problem is that I am not getting the
slides in the correct order. However, if I download the ppt file and run
the same program, The order of the slides is much closer to the real
order, i.e. at least I get the first few slides in order (and this is
what I need). Any idea how I can fix the problem?
Thanks,
Leila
---------------------------------------------------------------------
To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
Mailing List: http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project: http://jakarta.apache.org/poi/
Re: Get text from a URL pointing to a ppt file
Posted by Nick Burch <ni...@torchbox.com>.
On Thu, 10 Aug 2006, Leila Homaeian wrote:
> I am trying to use SlideShow.getSlides() to get slides from a URL
> pointing to a powerpoint file. The problem is that I am not getting the
> slides in the correct order. However, if I download the ppt file and run
> the same program, The order of the slides is much closer to the real
> order, i.e. at least I get the first few slides in order (and this is
> what I need). Any idea how I can fix the problem?
That sounds very odd. I'd try using your URL fetching code to just stream
the data to disk, and check from that. Does the data streamed to disk
differ from when you download via your web browser?
Also, are you using a recent SVN checkout of HSLF? There were some patches
from Yegor committed fairly recently that should've improved the slide
ordering detection
Nick
---------------------------------------------------------------------
To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
Mailing List: http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project: http://jakarta.apache.org/poi/
Re: Get text from a URL pointing to a ppt file
Posted by Yegor Kozlov <ye...@dinom.ru>.
Hi,
I think it can be caching issue.
I guess your code was something like this:
URL url = new URL("http://localhost:8080/analysis.ppt");
URLConnection conn = url.openConnection();
InputStream is = conn.getInputStream();
SlideShow ppt = new SlideShow(is); //the order of slides is incorrect
I would try to call conn.setUseCaches(false) before opening the input
stream:
URL url = new URL("http://localhost:8080/analysis.ppt");
URLConnection conn = url.openConnection();
conn.setUseCaches(false);
InputStream is = conn.getInputStream();
SlideShow ppt = new SlideShow(is); //Does it fix the problem?
Regards, Yegor
LH> Hello,
LH> I am trying to use SlideShow.getSlides() to get slides from a URL pointing
LH> to a powerpoint file. The problem is that I am not getting the
LH> slides in the correct order. However, if I download the ppt file and run
LH> the same program, The order of the slides is much closer to the real
LH> order, i.e. at least I get the first few slides in order (and this is
LH> what I need). Any idea how I can fix the problem?
LH> Thanks,
LH> Leila
LH> ---------------------------------------------------------------------
LH> To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
LH> Mailing List: http://jakarta.apache.org/site/mail2.html#poi
LH> The Apache Jakarta Poi Project: http://jakarta.apache.org/poi/
---------------------------------------------------------------------
To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
Mailing List: http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project: http://jakarta.apache.org/poi/