I would like to convert my presentation file (.ppt) into images then put it on app. It just just plain presentation with the ability for me to swipe left or right to change slides (images in this case). What method is the easiest? viewflipper? Picture galery? or any SDK ready for this? Sample code or URL will be great as I am still learning.
Asked
Active
Viewed 884 times
2 Answers
0
I think it will help you
SlideShow ppt = new SlideShow(new HSLFSlideShow("slideshow.ppt"));
//extract all pictures contained in the presentation
PictureData[] pdata = ppt.getPictureData();
for (int i = 0; i < pdata.length; i++){
PictureData pict = pdata[i];
// picture data
byte[] data = pict.getData();
int type = pict.getType();
String ext;
switch (type){
case Picture.JPEG: ext=".jpg"; break;
case Picture.PNG: ext=".png"; break;
case Picture.WMF: ext=".wmf"; break;
case Picture.EMF: ext=".emf"; break;
case Picture.PICT: ext=".pict"; break;
default: continue;
}
FileOutputStream out = new FileOutputStream("pict_"+i + ext);
out.write(data);
out.close();
}

Lavekush Agrawal
- 6,040
- 7
- 52
- 85

Pawan asati
- 292
- 2
- 13
-
Thanks Pawan. If I understand correctly, the above help me to convert my slide into picture file? what I need is to have viewer for the images instead. – user3599442 May 31 '14 at 13:39
0
I think you should go with ViewPager. native control in android. You can find sample code as well as more detail about control in this link.

itzmebibin
- 9,199
- 8
- 48
- 62

Paresh Dudhat
- 1,166
- 1
- 14
- 28