Is there any way to set the style of a cell when the validation failed ? The default style is a red cross, and I want to change the background color of the cell.
Thanks.
Is there any way to set the style of a cell when the validation failed ? The default style is a red cross, and I want to change the background color of the cell.
Thanks.
Hi,
Thank you for considering Aspose.
Well, your required feature is not currently supported with Aspose.Grid. We will look into it, if we can support it in our future release.
Thank You & Best Regards,
Hi,
Here is a solution to implement your need, you can follow it.
Please try the following steps:
Set the property OnCellErrorClientFunction=“onCellValidationError” in aspx.
Add the onCellValidationError client script function like:
function onCellValidationError(o)
{
o.style.backgroundImage = “url(’/agw_client/dot.gif’)”;
}
Customize the background image file to replace the foreground/background image url for your need.
You must use backgroundImage instead of backgroundColor, because GridWeb cannot restore the backgroudColor if validation succeeds.
Thank you.
Thank you, it’s working very fine.