Telerik Forums
UI for WPF Forum
1 answer
106 views
Looking at the deoms (Compass) I see this needle template:
<Grid x:Name="PART_Grid" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
                                <Grid.ColumnDefinitions> 
                                    <ColumnDefinition Width="*" /> 
                                    <!-- Column 0 - tail --> 
                                    <ColumnDefinition Width="*" /> 
                                    <!-- Column 1 - pin point --> 
                                    <ColumnDefinition Width="*" /> 
                                    <!-- Column 2 - arrow --> 
                                </Grid.ColumnDefinitions> 
                                <Grid.RowDefinitions> 
                                    <RowDefinition Height="*" /> 
                                </Grid.RowDefinitions> 

I guess the old one that appears in the documentation (without TemplatePart) is obsolete and even not properly working?
Andrey
Telerik team
 answered on 29 Apr 2010
1 answer
99 views
I have a child grid as below, but it doesn't honor Widths set to the columns in Xaml.  Also, even though I've set the FrozenColumnCount, when I scroll left or right, the entire child table scrolls left or right and the columns that are supposed to be frozen scroll as well.

<telerik:RadGridView.HierarchyChildTemplate>
                        <DataTemplate>
                            <telerik:RadGridView x:Name="RadGridView1" CanUserFreezeColumns="True" CanUserInsertRows="False"
                                                 CanUserReorderColumns="False" CanUserResizeColumns="True" FrozenColumnCount="8" ShowColumnHeaders="True" IsFilteringAllowed="False"
                                                 AutoGenerateColumns="False" ItemsSource="{Binding SkuForecastArchiveData}"  ShowGroupPanel="False" IsReadOnly="True">
                                <telerik:RadGridView.Columns>
                                    <telerik:GridViewDataColumn Header="Sku" DataMemberBinding="{Binding Sku}" Width="48" />
...
Yordanka
Telerik team
 answered on 28 Apr 2010
2 answers
73 views
How i can set the grid as non editable?, is this possible?
dennis
Top achievements
Rank 1
 answered on 28 Apr 2010
1 answer
106 views
Hi guys,

Check out the following XAML
<Window x:Class="WpfApplication28.MainWindow" 
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
        xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" 
        Title="MainWindow" Height="350" Width="525" Background="Gray"
    <Grid> 
        <Grid.Resources> 
            <ControlTemplate x:Key="Tubo"
                <telerik:RadialGauge Width="150" Height="150"
                    <telerik:RadialScale Name="radialScale" StartAngle="135" SweepAngle="270" Radius=".95" 
                            MajorTicks="5" MinorTicks="1" MiddleTicks="1" LabelRotationMode="None"
                        <telerik:RadialScale.Label> 
                            <telerik:LabelProperties Location="Inside" FontSize="20" Foreground="Red" /> 
                        </telerik:RadialScale.Label> 
                    </telerik:RadialScale> 
                </telerik:RadialGauge> 
            </ControlTemplate> 
            <Style TargetType="{x:Type Control}"
                <Setter Property="Template" Value="{StaticResource Tubo}"
                </Setter> 
            </Style> 
        </Grid.Resources> 
        <Grid.RowDefinitions> 
            <RowDefinition /> 
            <RowDefinition /> 
        </Grid.RowDefinitions> 
        <Control /> 
        <telerik:RadialGauge Grid.Row="1"
            <telerik:RadialScale Name="radialScale" StartAngle="135" SweepAngle="270" Radius=".95" 
                            MajorTicks="5" MinorTicks="1" MiddleTicks="1" LabelRotationMode="None"
                <telerik:RadialScale.Label> 
                    <telerik:LabelProperties Location="Inside" FontSize="20" Foreground="Red" /> 
                </telerik:RadialScale.Label> 
            </telerik:RadialScale> 
        </telerik:RadialGauge> 
    </Grid> 
</Window> 
 

It shows two gauges, first one defined through a controltemplate embedded in style while the other directly. The former doesn't apply Label properties at all nor MajorTicks (not shown) but it does apply Needle if one is specified.
Andrey
Telerik team
 answered on 28 Apr 2010
1 answer
100 views
Hi,

I am new to Telerik chart. Actually downloaded the wpf controls to try before purchasing. I have added the following
XAML:

 

 

<GroupBox Style="{DynamicResource NoTitledGroupBox}" Grid.Row="1" Margin="20,5,20,20">

 

 

 

     <telerikChart:RadChart x:Name="RadChart1">

 

 

 

     </telerikChart:RadChart>

 

 

 

</GroupBox>

 


Code:

RadChart1.DefaultView.ChartArea.AxisX.DefaultLabelFormat =

"{0:F2}"

 

RadChart1.DefaultView.ChartArea.AxisX.MaxValue = 1000

RadChart1.DefaultView.ChartArea.AxisX.MinValue = 0

RadChart1.DefaultView.ChartArea.AxisX.[Step] = 100.0

RadChart1.DefaultView.ChartArea.AxisY.ExtendDirection = AxisExtendDirection.Smart

RadChart1.DefaultView.ChartArea.AxisX.Step = 100.0

RadChart1.DefaultView.ChartArea.AxisY.Title =

"Head"

 

RadChart1.DefaultView.ChartArea.AxisX.Title =

"GPM"

 

 

'RadChart1.DefaultView.ChartArea.AxisY.AxisStyles.TitleStyle = TryCast(Resources("CustomAxisTitleStyle"), Style)

 

 

Dim dsSeries As DataSeries = GenerateSeries(obj.getAdjustedHeadCalc, obj.getAdjustedCapacity)

 

dsSeries.LegendLabel =

"Head"

 

dsSeries.Definition =

New LineSeriesDefinition

 

RadChart1.DefaultView.ChartArea.DataSeries.Add(dsSeries)

I have about 17 points. The YAxis draws the labels fine but I see some missing tick marks. I want 10 ticks on the XAxis but it keeps drawing 17 ticks and the labels are all messed up. Is there anything I am doing wrong?

I have attached the produced chart with the above code.

Regards,
Boaz

Ves
Telerik team
 answered on 28 Apr 2010
3 answers
196 views
Hi,

I would like to ask for help, I tried to find a solution in emos and forum threads, but I failed.
I have a DataTable binded to a RadGridView. One of the columns in the binded DataTable is date and I want to display/edit it in a RadDatePicker. Somehow I didn't manage to bind it correctly. I binded the date field to the GridViewDataColumn with DataMemberBinding, but I can not pass it to the template. I can not even pass it to a TextBlock template. However I managed to display and edit with a non-templated GridViewDataColumn. But my goal is to display and edit the date values with RadDatePicker. I guess the main difference is with your provided demo thet here I want to bind a datatable and I must use DataMemberBinding for its field, but I can not use it inside a CellTemplate. I would be greateful if you could ge me a tip or sample code how to resolve this problem.  Here is a sample:

 

 

 

<Window.Resources>

 

 

 

 

    <bl:TimeBand x:Key="timeBands"/>

 

</Window.Resources>

 

...

 

 

 

<telerik:RadGridView Name="grTimeBand" AutoGenerateColumns="False" ActionOnLostFocus="CommitEdit" ShowGroupPanel="False" ItemsSource="{Binding Source={StaticResource timeBands}, Path=TimeBandTable, debug:PresentationTraceSources.TraceLevel=High}">

 

 

 

 

    <telerik:RadGridView.Columns>

 

 

 

 

        <telerik:GridViewComboBoxColumn Header="InclAllSpecDays" Width="100" ItemsSourceBinding="{Binding Source={StaticResource booleanValues}, Path=BooleanValueList}" DataMemberBinding="{Binding INCLUSIVE_ALL_SPECIAL_DAYS}" />

 

 

 

 

        <telerik:GridViewDataColumn DataMemberBinding="{Binding START_TIME}">

 

 

 

 

            <telerik:GridViewDataColumn.CellTemplate>

 

 

 

 

                <DataTemplate>

 

 

 

 

                    <TextBlock Text="{Binding START_TIME, debug:PresentationTraceSources.TraceLevel=High}" /> ?????

 

 

 

 

                </DataTemplate>

 

 

 

 

            </telerik:GridViewDataColumn.CellTemplate>

 

 

 

 

            <telerik:GridViewDataColumn.CellEditTemplate>

 

 

 

 

                <DataTemplate>

 

 

 

 

                    <telerikInput:RadDatePicker SelectedDate="{Binding START_TIME, Mode=TwoWay}" />

 

 

 

 

                </DataTemplate>

 

 

 

 

            </telerik:GridViewDataColumn.CellEditTemplate>

 

 

 

 

        </telerik:GridViewDataColumn>

 

 

 

 

        <telerik:GridViewDataColumn Header="EndTime" Width="100" DataMemberBinding="{Binding END_TIME}"/>
        ...
                        
    </telerik:RadGridView.Columns>

 

 

 

 

 

 

 

 

</telerik:RadGridView>

 

Ferenc Gál
Top achievements
Rank 1
 answered on 28 Apr 2010
12 answers
447 views
Hello

A few days ago I had the problem, that I was binding a GridViewDataColumn to a Property that does not necessary exist on the type of the associated DataContext but in subclasses it does. Here a little overview of my support ticket post:

I'm trying to replace my DataGrid with a RadGridView from Telerik. My control has a ViewModel as DataContext which has a property "DbObject". It is of the type "DbBaseObject". Now there could be any descendant of this type filled into the GridView. Some of them may have a property "Name", some may not. The standard WPF-Controls are pretty soft when evaluating a property that doesn't exist -> they just show an empty value. The RadGridView gives me Exceptions: 
 
ArgumentException "Property with name Name cannot be found on type DbBaseObject" 
and afterwards 
Invalid property or field - 'Name' for type: DbBaseObject 
 
This is true, the DbBaseObject doesn't have a property "Name" but this shouldn't be a reason not to show a column. Is there anything I can do to soften this behavior up? 

The answer was, that somehow it is not possible with the Telerik GridView to bind to abstract classes and that I have to use a Converter to achieve this job. I did so and it worked although I was not 100% happy with this solution as in my opinion, databinding should be a lot softer. Now I'm confronted with the problem, that Grouping / Filtering does not really work as it gives me Exceptions - after searching this forum I found the following post that answers why it doesn't work:


Any other idea how I achieve what I want to achieve? (I was not able to answer the support ticket as my 60-Days-Support expired) 

Thanks
~NoRyb
Stefan Dobrev
Telerik team
 answered on 28 Apr 2010
2 answers
108 views
   hi, i am hu , I have download sales dashboard for wpf sourse, but I don't know how to use it and is there any chm or video about it.
haha 胡
Top achievements
Rank 1
 answered on 28 Apr 2010
1 answer
131 views
Currently I am setting the ItemsPerPage on the panel to get the look i want.  When I resize the window, the space between the items expands which is what I do not want.  To solve this, I bound the ItemsPerPage to a property on my MVVM to handle this and it works well in keeping my item spacing the way I want.  The problem is that the SelectedItem changes as I resize.  The ItemSource and the SelectedItem are bound to properties on my MVVM, and those 2 actual values never change, but what is displayed on the carousel as the SelectedItem does change.

How can I resize the carousel, keep the item spacing the same (by adding more items per page) AND keep the selected item to what it was before the resizing?

Thanks,
David Ribb
Milan
Telerik team
 answered on 27 Apr 2010
1 answer
128 views
We are currently using your wpf controls and have overriden the default styles on many of the controls.  Since upgrading our controls to your recent release, we are receiving numerous xaml errors regarding new parts the controls expect to find in the control templates.  I think our problems can be solved quickly if we had the style source for the recent release to compare whats missing in our existing control templates.  Where can I find the source for the themes you provide?  I have source for previous versions but I didnt find any in the zip files?

Thank you
Lawrence King
International Training Institute
Kalin Milanov
Telerik team
 answered on 27 Apr 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?