Hi all
I'm working with poi3.5 beta5
i have a problem when i try to read Or add background
Code for adding
SlideShow slideShow = new SlideShow();
SlideMaster master = slideShow.getSlidesMasters()[0];
Fill fill = master.getBackground().getFill();
int id = slideShow.addPicture(new File("c:\\bag.png"),
Picture.PNG);
fill.setFillType(Fill.FILL_PICTURE);
fill.setPictureData(id);
FileOutputStream out = new
FileOutputStream("c:\\MasterBackground.ppt");
slideShow.write(out);
out.close();
Code for reading
SlideShow syntheseDetaille=new SlideShow(new
HSLFSlideShow("c:\\Synthese_temp.ppt"));
SlideMaster master=syntheseDetaille.getSlidesMasters()[0];
Fill fill =master.getBackground().getFill();
OutputStream st=new FileOutputStream(new File("c:\\pic.jpg"));
st.write(fill.getPictureData().getData());
st.close();
//NULL POINTER EXCEPTION!!
--
View this message in context:
http://www.nabble.com/Background-PPT-error-%28urgent%21%29-tp23808770p23808770.html
Sent from the POI - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]