# Defining Alarm Zones Properties

## Content



Alarm Zones have two basic sets of properties. The first set of properties determines the boundaries of the Alarm Zone in reference to the chart's data values. Setting the [NearExtent](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.NearExtent.html) and [FarExtent](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.FarExtent.html) properties to values within the bounds of the X-axis sets the **Left** and **Right** boundaries of the AlarmZone. Conversely, setting the [UpperExtent](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.UpperExtent.html) and [LowerExtent](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.LowerExtent.html) properties to values within the bounds of the **Y-axis** sets the **Upper** and **Lower** boundaries of the Alarm Zone. For instance, to set the green AlarmZone in the above image the NearExtent would be 2.5, the FarExtent would be 4.5, the LowerExtent would be 8.0, and the UpperExtent would be 14.0. Notice that the names of these properties are [UpperExtent](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.UpperExtent.html), [LowerExtent](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.LowerExtent.html), [NearExtent](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.NearExtent.html), and [FarExtent](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.FarExtent.html) rather than **X**, **Y**, **Height**, and **Width**. One important benefit to Alarm Zones is that they are not static, but actually tied to the chart's data. This means that as the data changes, the Alarm Zones will change in relation to the data and not like one of the chart's visual attributes. To prevent the AlarmZones from vanishing when the data changes you can set the [MinHeight](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.MinHeight.html) and [MinWidth](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.MinWidth.html) properties. Also, the [MinHeight](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.MinHeight.html) and [MinWidth](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.MinWidth.html) properties allows the placement of an AlarmZone with fixed dimensions.

The second set of properties determines the style characteristics of the Alarm Zone. The [Shape](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.Shape.html), [BackColor](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.BackColor.html) and [PatternStyle](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.PatternStyle.html) properties can be set for the Alarm Zone. You can choose from three different types of shapes for Alarm Zones: **rectangle**, **ellipse**, and **polygon**. If you create a polygon shaped alarm zone you need to specify the [PolygonSource](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.PolygonData.PolygonSource.html) property from the **AlarmZone Collection Editor** at design time or at run time. Setting the [ForeColor](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.ForeColor.html) property sets the color of the pattern specified by the [PatternStyle](/componentone/api/win/online-chart2d/dotnet-framework-api/C1.Win.C1Chart.4.8/C1.Win.C1Chart.AlarmZone.PatternStyle.html) property.

## See Also

[Customizing Chart Elements](/componentone/docs/win/online-chart2d/customizingchartelem)