Hello, When using xlsIO v4.2.0.37 in the Windows Forms environment to esatblish conditional formatting for a text comparison, it fails as shown below. It only works if the FirstFornula contains a valid numeric value, also shown for comparison.
conditionalFormat.FormatType = ExcelCFType.CellValue;
conditionalFormat.FirstFormula = "1000"; //OK
conditionalFormat.FirstFormula = "FRED";
An unhandled exception of type ''System.ArgumentException'' occurred in syncfusion.xlsio.base.dllAdditional information: Can''t parse formula: FRED
AD
Administrator
Syncfusion Team
August 1, 2006 08:32 PM UTC
Hi Spivey,
I am able to reproduce the problem.I have filed a bug report regarding this issue.
Please track the status of this bug through the following link:http://www.syncfusion.com/support/issues/xlsio/Default.aspx?ToDo=view&questId=2487
Please let me know if you have any other queries.
Thanks,
Bharath.
AD
Administrator
Syncfusion Team
May 14, 2009 09:30 PM UTC
I'm using 7.2.0.19 and I'm seeing this problem. Has it been fixed?
GM
Geetha M
Syncfusion Team
May 18, 2009 06:17 AM UTC
Hi Brian,
Thank you for your interest in Syncfusion products.
This is not an issue as it expects only Formula to be passed in "FirstFormula" property. In case if a text is expected then it can be given as "\"FRED\"".
The below code works fine:
conditionalFormat.FirstFormula = "\"FRED\"";
//Setting format properties.
conditionalFormat.Operator = ExcelComparisonOperator.Equal;
conditionalFormat.FormatType = ExcelCFType.CellValue;
conditionalFormat.BackColorRGB = Color.FromArgb(238, 122, 3);
Please try using this modified code snippet and let me know if you have any questions.
Regards,
Geetha