<telerik:LineSeries ItemsSource="{Binding MyCrazyLineNodes}" ValueBinding="Value" CategoryBinding="Category" ShowLabels="False"> <telerik:LineSeries.PointTemplate> <DataTemplate> <Grid> <Canvas Margin="0,10,0,0" Visibility="{Binding IsValueVisible, [Converter stuff...}"> <TextBlock Text="{Binding Value}" /> </Canvas> <Path Data="M4,0 L8,4 L4,8 L0,4 Z" Fill="Red" Width="8" Height="8" Stretch="Fill" /> </Grid> </DataTemplate> </telerik:LineSeries.PointTemplate> <AxisStuffAndSoOn /></telerik:LineSeries><Style TargetType="{x:Type telerik:RadPane}"> <Setter Property="ContextMenuTemplate" Value="{x:Null}" /> </Style>
<chart:RadCartesianChart Grid.Column="0" Grid.Row="0"> <chart:RadCartesianChart.HorizontalAxis> <telerik:CategoricalAxis FontFamily="Segoe UI" FontSize="12"/> </chart:RadCartesianChart.HorizontalAxis> <chart:RadCartesianChart.VerticalAxis> <chartView:LinearAxis Minimum="0" Maximum="100"/> </chart:RadCartesianChart.VerticalAxis> <chartView:BarSeries ItemsSource="{Binding LogicalProcessors}" CategoryBinding="DisplayName" ValueBinding="Value"> <chartView:BarSeries.PointTemplate> <DataTemplate> <Rectangle Fill="Green"/> </DataTemplate> </chartView:BarSeries.PointTemplate> </chartView:BarSeries></chart:RadCartesianChart><ItemsControl Grid.Column="0" Grid.Row="1" ItemsSource="{Binding LogicalProcessors}"> <ItemsControl.ItemsPanel> <ItemsPanelTemplate> <StackPanel/> </ItemsPanelTemplate> </ItemsControl.ItemsPanel> <ItemsControl.ItemTemplate> <DataTemplate> <TextBlock Text="{Binding Value}"/> </DataTemplate> </ItemsControl.ItemTemplate></ItemsControl>Application.Current.Resources.MergedDictionaries.Clear()Dim res1 As ResourceDictionary = New ResourceDictionary() res1.Source = New Uri("/Telerik.Windows.Themes.Expression_Dark;component/Themes/System.Windows.xaml", UriKind.RelativeOrAbsolute)Dim res2 As ResourceDictionary = New ResourceDictionary()res2.Source = New Uri("/Telerik.Windows.Themes.Expression_Dark;component/Themes/Telerik.Windows.Controls.xaml", UriKind.RelativeOrAbsolute)Dim res3 As ResourceDictionary = New ResourceDictionary() res3.Source = New Uri("/Telerik.Windows.Themes.Expression_Dark;component/Themes/Telerik.Windows.Controls.Input.xaml", UriKind.RelativeOrAbsolute)...Application.Current.Resources.MergedDictionaries.Add(res1)Application.Current.Resources.MergedDictionaries.Add(res2)Application.Current.Resources.MergedDictionaries.Add(res3)Dim str As String = My.Application.Current.Resources.MergedDictionaries(1).Source.OriginalStringstr = Strings.Mid(str, 25, str.Length)str = Left(str, str.IndexOf(";"))'Returns the Theme's name in useDim colorPalette = MetroColors.PaletteInstanceDim converter As New System.Windows.Media.BrushConverterMe.gridStatus.Background = DirectCast(converter.ConvertFromString(colorPalette.AccentColor.ToString), Brush)1.) I have a barchart with vertical bars. Data is added to my chart in the elapsed event of a timer. When I add a new bar to the chart I want it placed on the right side. As new bars are added, I want existing bars to be pushed to the left. How do I do this please? I tried setting HorizontalAlignment and HorizontalContentAlignment on both the BarSeries and the Horizontal axis but neither works.
2.) I want to set the width of each bar. I am using GapLength at the moment to make the bars narrower but it does not work as the number of bars added to the chart increases. More specifically, I want to set the width of each bar and the space between them i.e. margin to some fixed amount and fill the chart from the right as described above.
Thanks,
Sam
<telerik:RadGridView AutoGenerateColumns="False" Margin="12,0,12,12" Name="radGridViewNeedsShipping" SelectionMode="Extended" ShowGroupPanel="False" Height="190" VerticalAlignment="Bottom" MouseDoubleClick="rgvOpenTicket"> <telerik:RadGridView.Columns> <telerik:GridViewDataColumn Header="PO Number" IsReadOnly="True" UniqueName="SerialNumber" /> <telerik:GridViewDataColumn Header="Customer" IsReadOnly="True" UniqueName="Customer.EntityName" /> <telerik:GridViewDataColumn Header="Ship By Date" IsReadOnly="True" UniqueName="TransactionDate" DataFormatString="{}{0:MM/dd/yyyy}"/> <telerik:GridViewDataColumn Header="Type" IsReadOnly="True" UniqueName="TransactionTypeId" /> </telerik:RadGridView.Columns> </telerik:RadGridView>private void Window_Loaded(object sender, RoutedEventArgs e) { radGridViewNeedsShipping.ItemsSource = InControlDataAccess.getTransactions(0).Where(i => (i.TransactionTypeId == 11 || i.TransactionTypeId == 12) && (i.HasBeenShipped == null || i.HasBeenShipped == false) && i.InProgress != null && i.InProgress != false).OrderBy(i => i.Id); }