Telerik Forums
UI for WPF Forum
2 answers
74 views

I need to get the fit of the maximum on the length of the control, either that or move the label below the line. 

For the first option, I was thinking of reducing the value,and then customizing the labeltext that shows up. Only issue is, not sure how to modify the textblock that shows that value. 

Second option, kind of related to the first one, how can I use a datatemplate to have a template where the label is below the line?

 

Please refer to image attached.

 

Thanks!

Martin Ivanov
Telerik team
 answered on 25 Jul 2018
3 answers
77 views

Hello all,

 

I am using a RadStacked100DataBar in order to display a percentage like fill bar (like in the attached image).

The value/s can change on refresh data, I would need an animation of the colored bar width changing. Is there a way to achieve this?

Thank you.

Rosca
Top achievements
Rank 1
 answered on 19 Jul 2017
1 answer
66 views

The documentation for RadDataBar mentions a set of 4 controls: 

  1. RadDataBar
  2. RadStackedDataBar
  3. RadStacked100DataBar
  4. RadHorizontalAxis

Number 4, RadHorizontalAxis, is what I need, but I can't find this control anywhere in R1 2017. Also no documentation on how to use it nor an example. What am I missing???

Regards
Heiko

Evgenia
Telerik team
 answered on 28 Apr 2017
3 answers
278 views
For some reason, I'm unable to apply a LabelText attribute on the RadDataBar. Its ControlTemplate contains a TextBlock which uses TemplateBinding to bind to the AppliedLabelMargin and LabelText properties, but they're not available.

What gives?
Evgenia
Telerik team
 answered on 22 Feb 2016
1 answer
39 views
I've added a simply line of Databar control, but when I run the application, an exception id fired:

https://www.dropbox.com/s/8ptw82rm7ui0wth/Screenshot%202015-03-21%2021.28.39.png?dl=0

that the code of xaml:
<Window x:Class="HierarchicalGroupingAndFilteringWithTreeView.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:local="clr-namespace:HierarchicalGroupingAndFilteringWithTreeView"
        xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
        Title="MainWindow" WindowState="Maximized">
    <Window.DataContext>
        <local:ViewModel />
    </Window.DataContext>
    <Window.Resources>
        <Style TargetType="telerik:RadTreeViewItem">
            <Setter Property="IsExpanded" Value="True" />
            <Setter Property="Margin" Value="0 2 0 2" />
        </Style>
        <DataTemplate x:Key="Team">
            <Grid>

                <TextBlock Text="{Binding Name}" />
            </Grid>
        </DataTemplate>
        <HierarchicalDataTemplate x:Key="Division" ItemTemplate="{StaticResource Team}" ItemsSource="{Binding Teams}">
            <TextBlock Text="{Binding Name}" />
        </HierarchicalDataTemplate>
        <telerik:GroupHeaderTemplateSelector x:Key="CustomGroupHeaderContentTemplateSelector">
            <telerik:GroupHeaderTemplateSelector.HorizontalTemplate>
                <DataTemplate>
                    <ContentPresenter Content="{Binding FormattedName}" Height="16" Margin="4"/>
                </DataTemplate>
            </telerik:GroupHeaderTemplateSelector.HorizontalTemplate>
            <telerik:GroupHeaderTemplateSelector.VerticalTemplate>
                <DataTemplate>
                    <ContentPresenter Content="" Height="16" VerticalAlignment="Top" />
                </DataTemplate>
            </telerik:GroupHeaderTemplateSelector.VerticalTemplate>
        </telerik:GroupHeaderTemplateSelector>
    </Window.Resources>

    <Grid>

        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="150" />
            <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>
        <telerik:RadDataBar Width="200" Height="30" VerticalAlignment="Top"></telerik:RadDataBar>

        <telerik:RadTreeView Grid.Row="1" ItemsSource="{Binding TreeViewItems}" ItemTemplate="{StaticResource Division}" Margin="-5,78,5,22">
            <telerik:EventToCommandBehavior.EventBindings>
                <telerik:EventBinding EventName="Expanded" Command="{Binding ExpandedCommand}" PassEventArgsToCommand="True" />
                <telerik:EventBinding EventName="Collapsed" Command="{Binding CollapsedCommand}"  PassEventArgsToCommand="True"/>
            </telerik:EventToCommandBehavior.EventBindings>
        </telerik:RadTreeView>
        <telerik:RadScheduleView Grid.Column="1" Grid.Row="1" 
                                 AppointmentsSource="{Binding Appointments}" 
                                 ResourceTypesSource="{Binding ResourceTypes}"
                                 GroupHeaderContentTemplateSelector="{StaticResource CustomGroupHeaderContentTemplateSelector}">
            <telerik:RadScheduleView.ViewDefinitions>
                <telerik:TimelineViewDefinition GroupFilter="{Binding GroupFilter}"
                                                MinorTickLength="30min" MajorTickLength="30min"  DayStartTime="7:30:00" DayEndTime="17:30:00" VisibleDays="1"  SmallChangeInterval="3d"/>
                <telerik:DayViewDefinition MinorTickLength="30min" MajorTickLength="30min"/>

            </telerik:RadScheduleView.ViewDefinitions>
            <telerik:RadScheduleView.GroupDescriptionsSource>
                <telerik:GroupDescriptionCollection>
                    <telerik:ResourceGroupDescription ResourceType="Common" />
                </telerik:GroupDescriptionCollection>
            </telerik:RadScheduleView.GroupDescriptionsSource>
            <telerik:RadScheduleView.DragDropBehavior>
                <local:ConflictCheckingDragDropBehavior  />
            </telerik:RadScheduleView.DragDropBehavior>
        </telerik:RadScheduleView>
    </Grid>

</Window>


Petar Marchev
Telerik team
 answered on 23 Mar 2015
1 answer
147 views
I need to style a RadStacked100DataBar similar to the attached picture, or I need to use a different control.  Do you guys have an example of the templates used for the RadStacked100DataBar and how best to re-template them to put a label in the center of each "section". 

Thank You
Paul
Evgenia
Telerik team
 answered on 19 Mar 2015
1 answer
106 views
I want to show multiple values in Tooltippath of each stackbaritem. I also want to change whole look and feel of tooltipPath.
How can I do that. Please suggest.
Martin Ivanov
Telerik team
 answered on 24 Jan 2014
1 answer
171 views
How can I do the same thing of building a BrushCollection and assigning to RadStackedDataBar programmatically in code behind. Thanks for answers.

<telerik:RadStackedDataBar
    Name="xStackedDataBar"
    Grid.Row="1"
    Grid.Column="1"
    Minimum="-20"
    Maximum="20"
    ValuePath="BarValue"
    ToolTipPath="ToolTipItem"
    Margin="10,5">
    <telerik:RadStackedDataBar.BarBrushes>
        <databars:BrushCollection>
          <SolidColorBrush Color="SlateBlue" />
          <SolidColorBrush Color="AntiqueWhite" />
          <SolidColorBrush Color="Aqua" />
          <SolidColorBrush Color="Green" />
          <SolidColorBrush Color="Blue" />
 
        </databars:BrushCollection>
    </telerik:RadStackedDataBar.BarBrushes>
</telerik:RadStackedDataBar>

Martin Ivanov
Telerik team
 answered on 22 Jan 2014
1 answer
67 views
I'm attempting to bind a floating point single (type is Single in VB.Net) to the value of databar and getting an error that a conversion cannot be made from Single to Double?

I've not experienced this with other controls.

A single is required in this case because the object is serialized and compressed. Using a single saves disk space.

Further, I need to provide the type Object to the Value property because in some cases I'm providing an Int32, whereas other times I am providing a Single. This is done via a datatemplate in a GridView.

It seems that if I provide anything pother than a double, the RadDataBar throws exceptions?

Am I overlooking something?
Tsvetie
Telerik team
 answered on 20 Jun 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
horváth
Top achievements
Rank 2
Iron
Iron
Steve
Top achievements
Rank 2
Iron
Erkki
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 2
Iron
Iron
Veteran
Jakub
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
horváth
Top achievements
Rank 2
Iron
Iron
Steve
Top achievements
Rank 2
Iron
Erkki
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 2
Iron
Iron
Veteran
Jakub
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?