Hi,
You can try to use jxls tag to create excel file , I think that will be more easy.

Core java