poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yair Zohar <y...@makam.co.il>
Subject Problem with hslf and powerpoint 2007
Date Tue, 03 May 2011 20:57:39 GMT
Hello,
I've coded a java servlet that creates a PowerPoint presentation that 
can be downloaded from my website.
While it works perfectly on OpenOffice, MS PowerPoint 2007 won't show 
the background images.
The fact that MS PowerPoint 2007 opens the presentation in compatibility 
mode may be related to the problem.

I'm using poi-3.7-20101029.jar

the response header is:

response.setHeader("Expires", "0");
response.setDateHeader("Last-Modified", System.currentTimeMillis());
response.setHeader("Pragma", "no-cache");
response.setHeader("Content-disposition",
       "attachment;filename=presentation.ppt");
response.setContentType("application/ms-powerpoint");


I tried also:

response.setContentType("application/vnd.ms-powerpoint");


I'm setting the background image with:

slide.setFollowMasterBackground(false);
Fill fill = slide.getBackground().getFill();
File backgroundImage = new File(path);
int idx = ppt.addPicture(backgroundImage, fileType);
fill.setFillType(Fill.FILL_PICTURE);
fill.setPictureData(idx);

Any help will be appreciated,
Yair Zohar.



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
For additional commands, e-mail: user-help@poi.apache.org


Mime
View raw message