The repro code listed below:
class Program
{
static void Main(string[] args)
{
Workbook wb = new Workbook();
Worksheet sheet1 = wb.Worksheets[0];
for (int i = 1; i <=500; ++i)
{
sheet1.Cells[“A” + i].PutValue(i * 100);
}
Range range = sheet1.Cells.CreateRange(0, 0, 500, 1);
range.Name = “Numbers”;
Worksheet sheet2 = wb.Worksheets[wb.Worksheets.Add()];
Validation validation = CreateValidation(sheet2, “Numbers”);
for (int i = 0; i < 1000; ++i)
{
for (int j = 0; j < 40; ++j)
{
CellArea listArea = new CellArea();
listArea.StartRow = i;
listArea.EndRow = i;
listArea.StartColumn = j;
listArea.EndColumn = j;
if (validation.AreaList.Count >= 50)
{
validation = CreateValidation(sheet2, “Numbers”);
}
validation.AreaList.Add(listArea);
}
}
wb.Save(“Repro.xls”);
}
private static Validation CreateValidation(Worksheet sheet, string rangeName)
{
Validation listVal = sheet.Validations[sheet.Validations.Add()];
listVal.Type = ValidationType.List;
listVal.Operator = OperatorType.None;
listVal.InCellDropDown = true;
listVal.ShowError = true;
listVal.AlertStyle = ValidationAlertType.Warning;
listVal.ErrorTitle = “Error”;
listVal.ErrorMessage = “The value is invalid. Please select from the list.”;
listVal.Formula1 = String.Format("={0}", rangeName);
return listVal;
}
}
If delete one row, the excel will be hang for a while and after that, some validation dropdownlist is disabled and doesn’t work properly.
For example, I delete line 990, see attached that lines above 990 do now work anymore
Hi,
Hi,
The issues you have found earlier (filed as CELLSNET-41492) have been fixed in this update.
This message was posted using Notification2Forum from Downloads module by Aspose Notifier.