well first of all it really a messy code, try to use simple code by putting corresponding code into seprate methods
then comes towards the actual problem.
would you please tell what kind of exception or error you are facing when you execute this code???
what comes in "j" after the following line executes??
tell us please.
i am Java +ve Now !
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com