private var allSegmentChartsOn:Boolean=true;
public function set segmentChartsOn(value:Boolean):void {
allSegmentChartsOn = value;
}
public function get segmentChartsOn():Boolean {
return allSegmentChartsOn;
}
var myLineSeries:LineSeries = new LineSeries();
myLineSeries.visible = allSegmentChartsOn;
>> is there anyway I need to do in order the visibility should be changed as we change allSegmentChartsOn variable in the code?
// Yes. This line takes care of that:
BindingUtils.bindProperty(myLineSeries, “visible”, this, “segmentChartsOn”);
The above line adapts the “visible” property of myLineSeries whenever the “segmentChartsOn” property of ‘this’ changes.

