Telerik Forums
UI for WPF Forum
2 answers
143 views
How would one set the theme (to metro) of a context menu programmatically?

Many thanks.

Rob
Rob
Top achievements
Rank 1
Iron
Iron
 answered on 06 Feb 2012
5 answers
266 views
We're evaluating the RadControls for use in our software, but are running into a bit of a brick wall with GridView. Our software allows the user to click items, then display data about them in the GridView. Each item that is chosen must refresh the grid, add new columns and rows, because the number of each required can vary. Every time the ItemsSource of the GridView is set, the memory used by the program shoots up 10meg or more, even though there are only a few rows being loaded in. 

Any thoughts? The controls in general seem good, but this is unfortunately a deal breaker if we can't get it to work...

We're running .NET 4.0 (C#), Win 7, 2011 Q3 RadControls Trial
Vlad
Telerik team
 answered on 06 Feb 2012
7 answers
285 views
Hi, 

I have a radgridview binded to a data-table. I need to make the first column of this grid Combo-box. I have tried the following and it did not worked out well as the combo-column is not showing the data-table data.
My code behind,
Class MainWindow
 
    Private Colours As String()
    Public Sub New()
 
        ' This call is required by the designer.
        InitializeComponent()
        Colours = New String(1) {}
        Colours(0) = "Yellow"
        Colours(1) = "Green"
 
        ' Add any initialization after the InitializeComponent() call.
        RadGridView1.ItemsSource = BindData()
 
    End Sub
    Public Function BindData()
        Dim dtTemp_Start As New DataTable
        If Not dtTemp_Start.Columns.Count > 0 Then
            Dim column As DataColumn = New DataColumn
            column.DataType = System.Type.GetType("System.Int32")
            With column
                .AutoIncrement = True
                .AutoIncrementSeed = 1
                .ReadOnly = True
                .Unique = True
                .ColumnName = "Auto_ID"
            End With
            dtTemp_Start.Columns.Add(column)
            dtTemp_Start.Columns.Add("tType", GetType(String))
            dtTemp_Start.Columns.Add("Expression", GetType(String))
            Dim sDataRow As DataRow
            sDataRow = dtTemp_Start.NewRow()
            sDataRow(1) = "black"
            sDataRow(2) = "bbk"
            dtTemp_Start.Rows.Add(sDataRow)
            ' dtTemp.Columns.Add("VarCollection", GetType(ObservableCollection(Of SimulationVariableInfo)))
            'dtTemp_Start.Columns.Add("ConditionCollection", GetType(clsCondCollection))
        End If
        Return dtTemp_Start
    End Function
    
    Private Sub RadGridView1_BeginningEdit(ByVal sender As System.Object, ByVal e As Telerik.Windows.Controls.GridViewBeginningEditRoutedEventArgs) Handles RadGridView1.BeginningEdit
        DirectCast(Me.RadGridView1.Columns("tType"), GridViewComboBoxColumn).ItemsSource = Colours
    End Sub
End Class

My XAML,
<telerik:RadGridView IsFilteringAllowed="False" ShowGroupPanel="False" AutoGenerateColumns="false" HorizontalAlignment="Left" Margin="0,67,0,0" Name="RadGridView1" VerticalAlignment="Top" Height="207" Width="503" >
           <telerik:RadGridView.Columns>
               <telerik:GridViewDataColumn Header="ID"  DataMemberBinding="{Binding Auto_ID}" />
               <telerik:GridViewComboBoxColumn  Header="Type"  DataMemberBinding="{Binding tType}"  >
                   
               </telerik:GridViewComboBoxColumn>
                
               <telerik:GridViewDataColumn Header="Expression"  DataMemberBinding="{Binding Expression}" />
           </telerik:RadGridView.Columns>
       </telerik:RadGridView>

I have attached the output I'm getting. 

I need to retain the value selected in the combo. replacing the original content.
 
regards,

SK
Pavel Pavlov
Telerik team
 answered on 06 Feb 2012
1 answer
131 views
Hi,

I would have a line graph with multiple y-axis series, can radChart "normalize" the data so that both series start from the same point ?

e.g

I have stock prices for Apple and Microsoft . Date on X-Axis,Normalized Price on Y-Axis. The prices of each stock are obviously totally different - but I want to see the relative differences between the two stocks. So I want both stocks to start at e.g 100% and then each day the price change will be converted to a %change in price. By doing this you can compare the 2 stocks directly in terms of price change.

rgds
Chris
Nikolay
Telerik team
 answered on 06 Feb 2012
2 answers
139 views
Hi everybody,

I am using telerik v 2.0.50727 for WPF (and i need to use this version, not any other one) and I got this "problem" when I try to export the items inside the RadGridView to Excel file: I need to export text which is in not US culture, with "á" and "ñ" for example. When I try to export it using the Export method from the RadGridView I get them changed.

I searched for information all along the forum, I tried everything I found:

Like...

public PageStart()
{
    Thread.CurrentThread.CurrentCulture = new CultureInfo("es-ES");
    Thread.CurrentThread.CurrentUICulture = new CultureInfo("es-ES");
 
    InitializeComponent();
}

and then trying even samples in other posts, like the one below, from LINK with the result in the picture.



I would ask for help to you, Telerik Team, please tell me how to adapt the culture from the RadGridView and make it export correctly the words like " á-Á " and the " ñ-Ñ ".

Thank you in advance and kind regards.

Alvaro.
Alvaro
Top achievements
Rank 1
 answered on 06 Feb 2012
1 answer
137 views
I'm building an app with Prism, MVVM and have a RadOutlookBar in a 'navigation region' and would like to change the 'content region' as RadOutlookBarItems are selected.
I would like to duplicate this type of functionality (from a menu item) in the RadOutlookBarItem
<telerik:RadMenuItem Header="New Account" Command="{Binding ShowView}" CommandParameter="NewAccount"> 

Any ideas on how to approach this?

Thanks,
 John
Tina Stancheva
Telerik team
 answered on 06 Feb 2012
0 answers
101 views
Hi,
          How can i load the carousel items using itemsource= linq objects please give me the sample.

Regards
Randy
Rajini
Top achievements
Rank 1
 asked on 06 Feb 2012
3 answers
93 views
It seems that the FlipDuration property of the RadBook control is only taken into account when the user has initiated a page turn.

When using the method .NextPage or setting the property .RightPageIndex the flip duration is not used. Is this by design?

Is there a way to slow down a page turn when using .NextPage or .RightPageIndex?

Thanks,

Jim
Kiril Stanoev
Telerik team
 answered on 06 Feb 2012
1 answer
99 views
I upgraded my WPF controls to version 2011.2.712.35 to fix a problem with adding the Camera Extension to a Chart for zooming.  When I did this I started getting a very odd error in a call to add a LegendItemMarkerShape to the Legend.  The chart xaml looks like this:

<UserControl x:Class="ABC.APP.ProfileWpf.ChartControl"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             mc:Ignorable="d"
             d:DesignHeight="300" d:DesignWidth="300" xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation">
    <Grid>
        <telerik:RadChart Margin="0" Name="mChartControl">
            <telerik:RadChart.DefaultSeriesDefinition>
                <telerik:Bar3DSeriesDefinition />
            </telerik:RadChart.DefaultSeriesDefinition>
  
            <telerik:RadChart.DefaultView>
                <telerik:ChartDefaultView>
                    <telerik:ChartDefaultView.ChartLegend>
                        <telerik:ChartLegend Name="legend" />
                    </telerik:ChartDefaultView.ChartLegend>
                    <telerik:ChartDefaultView.ChartArea>
                        <telerik:ChartArea LegendName="legend" DimensionMode="Strict3D">
                            <telerik:ChartArea.Extensions>
                                <telerik:CameraExtension />
                            </telerik:ChartArea.Extensions>
                        </telerik:ChartArea>
                    </telerik:ChartDefaultView.ChartArea>
                </telerik:ChartDefaultView>
            </telerik:RadChart.DefaultView>
        </telerik:RadChart>       
    </Grid>
and the code where I pass the marker shape looks like this:
mChartControl.DefaultView.ChartArea.Legend.LegendItemMarkerShape = value;

I am using VS2010 and the weird thing here is if I let the code run without inspecting the object in the QuickWatch 
Dialog then it will exception with the error "Object reference not set to an instance of an object.".  If I 
go ahead and inspect the mChartControl object and drill all of the way down to the Lengend object the Legend 
object will show "+Legend{Telerik.Windows.Controls.Charting.ChartLegend Header: Items.Count:0}" that it does
exist and the code will run as it should without exception, but if I just do a hover over the string in the 
IDE the Legend oject will show a value of NULL and will exception.  Please let me know what is going on here
and what can be done to correct this.  Thanks for your help out there.

Nikolay
Telerik team
 answered on 06 Feb 2012
1 answer
182 views
For example, I have a line chart with a data series. How can I know the pixel position relateve to the left-top of chart control of a data point in chart?

Thanks!
Nikolay
Telerik team
 answered on 06 Feb 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?