Hi ,
This is madhu and my doubt is that How can I get Merge cells data ac it is into my word document.
My code is like
for (int rowIndex = 103; rowIndex <=111; rowIndex++)
{
ArrayList list=new ArrayList();
int x=0;
for(int colIndex=1;colIndex<=10;colIndex++)
{
if(worksheet.getCell(rowIndex,colIndex).getStringValue().equalsIgnoreCase("0"))
{
exceldata="";
}
else
{
exceldata=worksheet.getCells().getCell(rowIndex, colIndex).getStringValue();
}
list.add(x,exceldata);
x++;
}
lists.add(new com.crisil.Map(list));
a++;
}
com.crisil.MailMerge customersDataSource = new com.crisil.MailMerge(lists,a,tablename[data],columns[data]);
doc.getMailMerge().executeWithRegions(customersDataSource);
And I defined all the interface methods and it is working for other cases. But for the Merge cells it is not coming.
Only two lines are comig.
Here I am attaching my Excel file.
Thanks
Madhu