Received : 2007/09/07 09:19:07
Message : hi, i am using the latest version of the aspose.cells for .NET framework 2.0, i am getting this error stating "The same worksheet name already exists error". i never had the problem while using the older versions of the aspose.cells. i've read forums related to this error, did as it was stated in the forums, but couldnt get out of this error. if you need any further details please let me know. thanks. Vijay
the above mentioned code was workign fine with the previous version of aspose.cell v4.0.2.0 .. the problem started when i upgraded to the new version of aspose.cell v4.3.0.0..
The problem may be caused by that your two files have same worksheet name. I will check and fix this issue in the start of next week. Thanks for your patience.
I have made sure that the file names of the two files are different by adding "pg1" and "pg2" respectively at the end of the file names. I appreciate for the quick response. Have a nice weekend.. i will be waiting for the fix.
Quick question, what is the max lenght for the file name, currently my file name has 28 characters "5roaef2cm1epy5alkxgunoqo_pg1.xls" and "5roaef2cm1epy5alkxgunoqo_pg2.xls" is there any limitation for the file length, please let me know, so that i can look into the code to fix it.
Well, I think there is no problem with your file names or their size. I tested a bit, there is no problem with Workbook.Combine method as it works fine.
Could you please post your both template files here. So, that we may check and figure out the issue.
Hey Amjad.. this is the exact error i am getting..
System.Exception was caught Message="The same worksheet name already exists" Source="Aspose.Cells" StackTrace: at Aspose.Cells.Worksheet.set_Name(String value) at Aspose.Cells.Worksheets.xcc75e504ef58a07f(Worksheets xf71a0df303a78bf4) at Aspose.Cells.Workbook.Combine(Workbook secondWorkbook) at PNLMS.ViewSDFRept.mergeXLs(String doc1, String doc2, String path) in
As Laurence told you that the problem may be caused by that your two files have same worksheet name. I checked the two files you posted i.e., "5roaef2cm1epy5alkxgunoqo_pg1.xls" and "5roaef2cm1epy5alkxgunoqo_pg2". Both templates have a worksheet named "Sheet1", So you must change the worksheet name of any workbook before combining them.