We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Hidding first worksheet

Hi:

I set the propertie IsVisible to false using the first worksheet, but when I open it with Excel 2007 the workbook has an unnormal behavior. Try the code below, open the workbook and click the first visible worksheet name.

Thanks, beforehand.

Cells cells;

Worksheet ws;

Workbook wb = new Workbook();

int si;

cells = wb.Worksheets[0].Cells;

cells[0,0].PutValue("This sheet is invisible");

si = wb.Worksheets.Add();

cells = wb.Worksheets[si].Cells;

cells[0, 0].PutValue("This sheet is visible");

wb.Worksheets[0].IsVisible = false;

wb.Save("C:\\book1.xls", FileFormatType.Default);

Hi,

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thank you for sharing the sample code.

We have found your mentioned issue after an initial test. We will look into it and get back to you soon. Your issue has been registered in our internal issue tracking system with issue id: CELLSNET-14882.

Thank You & Best Regards,

Hi,

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Please try the attached latest version of Aspose.Cells. We have fixed your mentioned issue.

Thank You & Best Regards,

Perfect, works fine.

Thank you.

Hi:

Making another test to the problem, I found that it persist. Please, look at this example and you will find that strange behavior again, when you click the tabs in Excel 97 (we are using version 4.8.2.10).

Note: It works really fine with "Move(1)", but that's not a professional solution to the problem.


Thanks beforehand.


var wb = new Workbook();
int indexWs;

var c0 = wb.Worksheets[0].Cells;
c0[0, 0].PutValue("WorkSheet: Default");
wb.Worksheets[0].Name = "Default";

indexWs = wb.Worksheets.Add();
var c1 = wb.Worksheets[indexWs].Cells;
c1[0, 0].PutValue("WorkSheet: Chart1");
wb.Worksheets[indexWs].Name = "Chart1";

indexWs = wb.Worksheets.Add();
var c2 = wb.Worksheets[indexWs].Cells;
c2[0, 0].PutValue("WorkSheet: Data for chart 1");
wb.Worksheets[indexWs].Name = "DataSheetForChart1";

indexWs = wb.Worksheets.Add();
var c3 = wb.Worksheets[indexWs].Cells;
c3[0, 0].PutValue("WorkSheet: Chart2");
wb.Worksheets[indexWs].Name = "Chart2";

indexWs = wb.Worksheets.Add();
var c4 = wb.Worksheets[indexWs].Cells;
c4[0, 0].PutValue("WorkSheet: Data for chart 2");
wb.Worksheets[indexWs].Name = "DataSheetForChart2";

//wb.Worksheets[0].Move(1);
wb.Worksheets["DataSheetForChart1"].IsVisible = false;
wb.Worksheets["DataSheetForChart2"].IsVisible = false;
wb.Worksheets["Default"].IsVisible = false;

wb.Save("C:\\book1.xlsx", FileFormatType.Excel2007Xlsx);

Hi,

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thank you for sharing the sample code.

We have found your mentioned issue after an initial test. We have reopened your issue (issue id: CELLSNET-14882). We will look into it and get back to you soon.

Thank You & Best Regards,

Hi,

Please try the attached version, we have resolved your issue.

Thank you.

Thanks Amjad.

Now it's working fine.

Alejandro Romero

The issues you have found earlier (filed as 14882) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.