try {
if (isSimpleColorMode()){
setColorProp(AnyConverter.toInt(xProps.getPropertyValue("FillColor")));
}
if(isGradientColorMode()){
Gradient aGradient = (Gradient)xProps.getPropertyValue("FillGradient");
setStartColorProp(aGradient.StartColor);
setEndColorProp(aGradient.EndColor);
if(aGradient.Angle == 900)
setGradientDirectionProp(Diagram.HORIZONTAL);
}