Telerik Forums
UI for WPF Forum
1 answer
365 views
Hello,
I need to disable the cell edit based on some properties of my viewmodel.... for standard GridViewDataColumn 

I've done
<telerik:GridViewDataColumn DataMemberBinding="{Binding MULTIPLIER_DA,Mode=TwoWay}" Header="Size da" UniqueName="MULTIPLIER_DA" IsEnabled="{Binding CanUserAdd, RelativeSource={RelativeSource FindAncestor,AncestorType={x:Type Grid}}}"  >
                  <telerik:GridViewDataColumn.CellEditTemplate>
                      <DataTemplate>
                          <TextBox Text="{Binding MULTIPLIER_DA,Mode=TwoWay}" IsEnabled="{Binding DataContext.CanUserAdd, RelativeSource={RelativeSource AncestorType={x:Type telerik:RadGridView}}}"></TextBox>
                      </DataTemplate>
                  </telerik:GridViewDataColumn.CellEditTemplate>
              </telerik:GridViewDataColumn>

How do I do it for Combo and Numeric?
Thanks
Dimitrina
Telerik team
 answered on 05 Jun 2014
1 answer
75 views
Am new to this telerik controls and C#; am using the RadTreeListView - in one column am adding the UserControl which will some set of control also i need to take the values from the user control to main radtreelist view observableCollection

Could you please help how we need to do it.
Dimitrina
Telerik team
 answered on 05 Jun 2014
1 answer
142 views
hi,

I use radchart in my project, since i use NoXaml dll, my DataSeries no longer displayed.  I try to define the SerieStyle on the chart area and on the SplineAreaSeriesDefinition and PieSeries but it doesn't works.

In the OutPutWindow: i got a warning when i click on the legend : System.Windows.Data Warning: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='Telerik.Windows.Controls.Charting.ChartLegend', AncestorLevel='1''. BindingExpression:Path=LegendItemMarkerShape; DataItem=null; target element is 'ChartLegendItem' (Name=''); target property is 'MarkerShape' (type 'MarkerShape')

This is the xaml code :

<telerik:RadChart telerik:StyleManager.Theme="Windows8" x:Name="radAreaChart" UseDefaultLayout="False" BorderThickness="0" Background="{x:Null}" BorderBrush="{x:Null}" >
                            <Grid>
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="auto"></RowDefinition>
                                    <RowDefinition Height="*"></RowDefinition>
                                </Grid.RowDefinitions>
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="auto"/>
 
                                </Grid.ColumnDefinitions>
                                <telerik:ChartTitle telerik:StyleManager.Theme="Windows8" x:Name="AreaChartTitle" HorizontalAlignment="Center" Content="{Binding Resource.ConnectionPerProfile}"
                                        Grid.Row="0" Grid.Column="1" Background="{x:Null}" FontFamily="Segoe UI Semibold" BorderThickness="0" OuterBorderBrush="{x:Null}" FontSize="13.333">
                                </telerik:ChartTitle>
                                <telerik:ChartArea telerik:StyleManager.Theme="Windows8"  Grid.Row="1" x:Name="AreaChart"    Margin="0"  LegendName="AreaChartLegend">
 
                                </telerik:ChartArea>
 
                                <telerik:ChartLegend telerik:StyleManager.Theme="Windows8" Grid.Row="1" x:Name="AreaChartLegend" Header="{Binding Resource.Legend}" Margin="-4,0" Grid.Column="1" />
                            </Grid>
                        </telerik:RadChart>



And this is my C# Code to add Series
AreaChart.DataSeries.Clear();
           AreaChart.AxisX.AutoRange = true;
           AreaChart.AxisY.AxisStyles.AlternateStripLineStyle = this.Resources["HorizontalStripLineStyle"] as Style;
           AreaChart.SeriesStyles.SplineAreaSeriesStyle = this.Resources["ScatterAreaSeriesStyle"] as Style;
           DataSeries chartProfilesSeries = new DataSeries();
                     
           chartProfilesSeries.Definition = new SplineAreaSeriesDefinition();
 
           chartProfilesSeries.Definition.SeriesStyle = this.Resources["ScatterAreaSeriesStyle"] as Style;
 
           if (null != (this.DataContext as MainViewModel).LstChartTotalDateConnexion)
           {
               foreach (ChartsDateConnectionDTO c in (this.DataContext as MainViewModel).LstChartTotalDateConnexion)
               {
                   chartProfilesSeries.Add(new DataPoint()
                   {
                       //Label = String.Format("{0} : {1} ", Strings.TotalOfconnection, c.Date.ToString("dd/MM")),
                       YValue = c.Connection,
                       XCategory = c.Date.ToString("dd/MM"),
                       Tooltip = String.Format("{0} du {1} ", Strings.TotalOfconnection, c.Date.ToString("dd/MM"))
                   });
               }
               chartProfilesSeries.Definition.SeriesName = String.Format("{0}", Strings.TotalOfconnection);
               chartProfilesSeries.LegendLabel = String.Format("{0}", Strings.TotalOfconnection);
               chartProfilesSeries.Definition.ShowItemToolTips = true;
               chartProfilesSeries.Definition.ShowItemLabels = true;
               chartProfilesSeries.Definition.InteractivitySettings.HoverScope = InteractivityScope.Series;
               chartProfilesSeries.Definition.InteractivitySettings.SelectionScope = InteractivityScope.Series;
 
 
               AreaChart.DataSeries.Add(chartProfilesSeries);

Thanks for you help

Best regards

Petar Marchev
Telerik team
 answered on 05 Jun 2014
5 answers
97 views

I have a Radlistbox binded trough ItemsSource and Windows8TouchTheme applied.

Inside each item in RadListBox there is a button with a click event.

If the item is not selected the event is fired, but if the item is selected the event is NOT fired.

If I remove the Windows8TouchTheme the event is always fired.

A think this is a bug, any workaround for this?

Alek
Telerik team
 answered on 05 Jun 2014
2 answers
116 views
I am using a TreeListView and have multiple roots on my tree but they share a common child.
A -> B
D -> B
B -> C

I would expect to see two roots A and D which expand out to
A
  B
    C
D
  B
    C
The TreeListView roughly displays this but expanding and collapsing is behaving strangely.
If I expand B it sometimes expands both Bs and sometimes C becomes its own row that will not collapse into B.
Can someone help explain this behavior to me?






















































Dimitrina
Telerik team
 answered on 05 Jun 2014
6 answers
93 views
Hi Telerik,

I'm testing the telerik components in order to see if we could use them in our products. I was very happy to see the nice themes you guys provide. Although, I can't make StyleManager work.

There is no problem when creating a WPF application, but the following project produces errors all the time (unable to locate the source for Themes.cs):

I create a class library with some XAMLs. This class library is registered to be com accessible in order to make 3d party softwares (managed and unmanaged) able to use our dll. This fails however when I use a stylemanager anywhere on the XAML.

I've provided 2 solutions as an example. testTelerikStyleManager creates the com accessible dll (and also a debug forms application => In which the stylemanager doesn't provide an error) and testTelerikStyleManager2 which has a forms application that will create an instance of our com-accessible dll. That's where stylemanager crashes.

download: http://www.dstudiofs.eu/uitwissel/testTelerikStyleManager.rar

If you would like to test on your machines, the workflow is:
1 build testTelerikStyleManager in debug mode to register Class1 for com interop
2 open testTelerikStyleManager2 and start debugging.... The error should be shown in a MessageBox when clicking the button

Kind regards
Masha
Telerik team
 answered on 05 Jun 2014
3 answers
137 views
I am using one grid inside radcombobox just like the xaml bellow.

      

  
<telerik:RadComboBox DisplayMemberPath="Descricao" Name="radComboBoxResultado" Grid.Column="2" StaysOpenOnEdit="True" Height="26">             <telerik:RadComboBox.Items>                 <telerik:RadComboBoxItem>                     <telerik:RadComboBoxItem.Template>                         <ControlTemplate>                             <Grid>                                 <Grid.RowDefinitions>                                     <RowDefinition Height="*"></RowDefinition>                                     <RowDefinition Height="*"></RowDefinition>                                 </Grid.RowDefinitions>                                 <telerik:RadGridView  x:Name="RadGridView" AutoGenerateColumns="False" ShowGroupPanel="False" CanUserFreezeColumns="False"                                               RowIndicatorVisibility="Collapsed" IsReadOnly="True" MinWidth="300" MaxWidth="600"                                              IsFilteringAllowed="False" ItemsSource="{Binding PagedSource, ElementName=RadDataPager}" SelectionChanged="RadGridView_SelectionChanged"                                              Height="150" SelectedItem="{Binding SelectedItem, Mode=TwoWay}" Loaded="RadGridViewResultadoBusca_Loaded">                                     <telerik:RadGridView.Columns>                                         <telerik:GridViewDataColumn Header="Referência" Width="120" DataMemberBinding="{Binding CodigoProduto}" IsReadOnly="True"></telerik:GridViewDataColumn>                                         <telerik:GridViewDataColumn Header="Produto" Width="*" DataMemberBinding="{Binding Descricao}" IsReadOnly="True"></telerik:GridViewDataColumn>                                         <telerik:GridViewDataColumn Header="Venda" Width="*" DataMemberBinding="{Binding ValorVenda}" DataFormatString="C2"  IsReadOnly="True"></telerik:GridViewDataColumn>                                     </telerik:RadGridView.Columns>                                 </telerik:RadGridView>                                 <telerik:RadDataPager Name="RadDataPager" Grid.Row="1" DisplayMode="FirstLastNumeric,Last" PageSize="20" Loaded="RadDataPager_Loaded"></telerik:RadDataPager>                             </Grid>                         </ControlTemplate>                     </telerik:RadComboBoxItem.Template>                 </telerik:RadComboBoxItem>             </telerik:RadComboBox.Items>         </telerik:RadComboBox>



Everything is ok but when i select the row in grid i'd like the text to appear in Text property of RadcomboBox  .

I've tried to binding the selected items together, and does not works, as well as, implement the selectedChnaged of the grid to set the combo.Text property with no success.


How can i achieve this?

Thanks
Yana
Telerik team
 answered on 05 Jun 2014
4 answers
298 views
Hello!

I need to process PreviewDrop  event from telerik's DragDropManager, and I am using Prism 5.0 in my WPF application.
I tried to search documentation and forums, but I was not able to find examples of how can I subscribe my command from ViewModel with the DragDropManager event PreviewDrop to be able to check if operation can be done, or I need to cancel the drop.

Can anyone help me with this?
Dmitry
Top achievements
Rank 1
 answered on 04 Jun 2014
1 answer
108 views
I want to add my custom attribute in SaveLayout.xml (RadDocking.SaveLayout).

See attach file.

and How to read that attribute for radpane header visible hidde by RadDocking.LoadLayout

I want to your recommand.




George
Telerik team
 answered on 04 Jun 2014
1 answer
73 views
http://www.telerik.com/forums/broken-intellisense-after-adding-tileview-and-radialgauge-to-the-project
Same problem as posted above.  
.Net 4.5, VS 2012.
Problem appeared after adding a TileList.  Removing the TileList didnt fix it.  
Neither did rebooting, clearing bin directory and obj directory.  
Boris
Telerik team
 answered on 04 Jun 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?