Select to view content in your preferred language

How to set start values for chart axis

1720
0
12-14-2012 06:43 AM
DonFreeman
Emerging Contributor
When my chart displays (see code below) it automatically decides what value to use as the minimum or start value for the y axis. Is there a way I can force it to always start at zero (0)?

Thanks
<toolkit:Chart x:Name="MyChart2"
            Title="Average Daily Traffic" 
          esri:GraphicsLayer.MapTipHideDelay="0:0:3" 
          Background="LightGray"  
          LegendStyle="{StaticResource BlankLegendStyle}" 
          TitleStyle="{StaticResource SmallTitleStyle}"          
          Height="225"
          Width="330">
       
       <toolkit:Chart.Series>
        <toolkit:ColumnSeries Title="ADT" IndependentValueBinding="{Binding Attributes[_year]}" 
                                                  DependentValueBinding="{Binding Attributes[adt]}">
         <toolkit:ColumnSeries.DataPointStyle>
          <Style TargetType="toolkit:DataPoint">
           <Setter Property="Template">
            <Setter.Value>
             <ControlTemplate TargetType="toolkit:ColumnDataPoint">
              <Grid Background="#FF51626F">
               <TextBlock Text="{TemplateBinding FormattedDependentValue}" 
                                                                   FontWeight="Bold" FontSize="8" 
                                                                   HorizontalAlignment="Stretch"
                                                                   TextAlignment="Center" />
              </Grid>
             </ControlTemplate>
            </Setter.Value>
           </Setter>
          </Style>
         </toolkit:ColumnSeries.DataPointStyle>
        </toolkit:ColumnSeries>
       </toolkit:Chart.Series>
      </toolkit:Chart>
0 Kudos
0 Replies