Telerik Forums
UI for WPF Forum
1 answer
100 views
Hello

It it possible to skip copying header cell content for particular column? For cells content I can use CopyingCellClipboardContent event. Is there any event for header cells?

I found in example CopyPasteFunctionality case where for Copied event there are made some modifications. So for my case I can use this approach but I am looking for some simpler.
Maya
Telerik team
 answered on 11 Feb 2015
1 answer
184 views
I'm looking for an imagemap control for WPF.  I'm trying to accomplish the example shown in the Ajax controls here

The idea is to be able to define regions on top of an image to use for navigation or showing status.

Thanks
Martin Ivanov
Telerik team
 answered on 11 Feb 2015
3 answers
128 views
Hello supporters and freinds!

I have a simple situation:

1. Window that his flowDirection is RightToLeft.
2. Within the window, i have a GridView with many columns, and the first column is frozen.
3. The columns has a style that set flowDirection and alignment. I need it to show numbers correctly.

When i scroll the columns, the columns are overlapping, and the display is goes awry.
Is there a way to fix it?

This is the core xaml markup:

<telerik:RadGridView ItemsSource="{Binding DataItems}" FrozenColumnCount="1">
    <telerik:RadGridView.Columns>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Name}" />
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field1}" Style="{StaticResource MoneyColumnStyle}"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field2}" Style="{StaticResource MoneyColumnStyle}"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field3}" Style="{StaticResource IntegerColumnStyle}"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field4}" Style="{StaticResource MoneyColumnStyle}"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field5}" Style="{StaticResource MoneyColumnStyle}"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field6}" Style="{StaticResource IntegerColumnStyle}"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field7}" Style="{StaticResource MoneyColumnStyle}"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field8}" Style="{StaticResource MoneyColumnStyle}"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Field10}" Style="{StaticResource IntegerColumnStyle}"/>
    </telerik:RadGridView.Columns>
</telerik:RadGridView>



the column styles:

<Style TargetType="{x:Type telerik:GridViewCell}" x:Key="NumericCellStyle" BasedOn="{StaticResource GridViewCellStyle}">
    <Setter Property="TextBlock.FlowDirection" Value="LeftToRight" />
</Style>
 
<Style TargetType="{x:Type telerik:GridViewBoundColumnBase}" x:Key="NumericColumnStyle">
    <Setter Property="CellStyle" Value="{StaticResource NumericCellStyle}" />
    <Setter Property="TextAlignment" Value="Right" />
</Style>
 
<!-- interger style -->
<Style TargetType="{x:Type telerik:GridViewBoundColumnBase}" x:Key="IntegerColumnStyle" BasedOn="{StaticResource NumericColumnStyle}">
    <Setter Property="DataFormatString" Value="#,###" />
</Style>
 
<!-- money style -->
<Style TargetType="{x:Type telerik:GridViewBoundColumnBase}" x:Key="MoneyColumnStyle" BasedOn="{StaticResource NumericColumnStyle}">
    <Setter Property="DataFormatString" Value="#,##0.00" />
</Style>

I attach a picture to show the problem.
thanks for any answer!


Yehudah
Top achievements
Rank 1
 answered on 10 Feb 2015
2 answers
309 views
I've been trying out the RadSpreadsheet control in a small test application and am seeing some odd scrolling behavior, even within the provided samples.  (I'm using the 2014 Q3 version:  2014.3.1202.45.)

When there are enough rows in the viewable area to make paging up or down possible (for example, the viewport shows 20 rows and the spreadsheet holds 100 rows), clicking on the scrollbar background only moves the contents up or down by a single row.

I've attached an event handler to the sheet's ScrollBarsProvider.VerticalScrollBar.Scroll event, and I'm observing that the ScrollEventType is indeed LargeIncrement as expected, and the eventArgs.NewValue contents appear to be an expected large value.... however, the position within the sheet only moves by a single row.  This occurs within unmodified projects within the Telerik's xaml-sdk repository found on GitHub: https://github.com/telerik/xaml-sdk

What is going on with the scrolling?  What can I do to make the vertical scrollbar behave as expected?

(Also, I just noticed the horizontal scrollbar is behaving in the same way - only scrolling by a single column at a time.)
Sandra
Top achievements
Rank 1
 answered on 10 Feb 2015
1 answer
106 views
There is grid with object which implement INotifyDataErrorInfo for validation and ValidatesOnDataErrors="InViewMode".
So basically grid is used only to highlight errors.

Everything works great, but if there is error, grid highlights each cell with incorrect value and additionally whole row.

Is there way to highlight only cells, not whole row?

Thanks,
Michael
Maya
Telerik team
 answered on 10 Feb 2015
3 answers
97 views
Hi all.

I am trying this scheduleview and is very good, but i dont know how make this.

I need diferent counts of beds in rooms. Can you help me? Thanks
For imaging, I upload image.

Miro
Nasko
Telerik team
 answered on 10 Feb 2015
2 answers
62 views
My co-worker and I downloaded the WPF trial library, and both of us are having an absolutely horrendous time with the RadSplitButton.

I was happily typing out the XAML (I'm faster with the keyboard than drag 'n drop with the mouse), and I added a RadSplitButton by typing out
"<telerik:RadSplitButton  Content="A Split Button", HorizontalAlignment="Center", VerticalAlignment="Top" />"
But then I decided I wanted to move the HorizontalAlignment to Right instead of Center.  So I used the arrow keys to put the cursor inside of that XAML line, and focus was moved to the designer window, and no longer in the XAML editor.  Every attempt at putting the cursor between "<" and "/>" (inclusive) was met with an instantaneous focus shift to the designer. 

I was able to change the setting using the XAML editor only view (no split view with the designer with XAML editor).

I was also able to get cursor focus back into the RadSplitButton entry by entering some invalid XAML in another place in the file.  However, when the XAML is correct, the cursor will NOT enter the RadSplitButton.


Kiril Vandov
Telerik team
 answered on 10 Feb 2015
3 answers
228 views
I've been able to programmatically set the SelectedItem in a WPF RadGridView and then call ScrollIntoView to get it to be visible in the grid.  But when I couple that with a RadDataPager it stops working.  I suspect I have to do something like Scroll in the pager, or instead of.  I have an object with a public SelectedItem that I had been passing into the gridview.ScrollIntoView.  Is there something like this I need to do to get at the right page of the DataPager, so my selected item shows up?
Lawrence
Top achievements
Rank 2
Iron
 answered on 10 Feb 2015
5 answers
1.1K+ views
Hello,

I have a user control with 2 RadGridView controls on it, code bellow. This gets loaded on the main window with a button click.
The problem I have is that there is a noticeable lag when this UserControl gets viewed on the screen 1st time. When the view changes and I go back to this view again then it's instantaneous so there is a perf degradation only at the 1st time viewing/loading it.

The perf degradation is noticeable even when there is no bindings to RadGridView columns, or even with 1 RagGridView and 1 column in the control.
I captured a perf report on VS viewing/loading this control multiple times, attached file perf.png, where you can clearly see the big CPU spike on the very first load but from there on it's not notifiable, the degradation seems to be coming from Telerik.Windows.Controls.GridView.GridViewCellsPanel.MeasureCell.
    
I've also looked at the troubleshooting documentation here but it didn't help.

Can you please help with my xaml bellow to see if this degradation is somehow coming from the way I've nested the GridView or defined the sizes?

I can send over a full project with a repro if needed.

Thank you!


<UserControl x:Class="SlowGrid.Views.UserControl1"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
             d:DesignHeight="610"
             d:DesignWidth="1000"
             mc:Ignorable="d">
    <Grid>
        <telerik:RadDocking Width="Auto"
                            Height="Auto"
                            HasDocumentHost="False">
            <telerik:RadSplitContainer InitialPosition="DockedTop" Orientation="Vertical">
                <telerik:RadSplitContainer InitialPosition="DockedTop" telerik:ProportionalStackPanel.RelativeSize="250, 250">
                    <telerik:RadPaneGroup FontSize="13" telerik:StyleManager.Theme="Summer">
                        <telerik:RadPane CanUserClose="False" Header="a">
                            <telerik:RadGridView AutoGenerateColumns="False"
                                                 FontSize="14"
                                                 IsSynchronizedWithCurrentItem="True"
                                                 RowIndicatorVisibility="Collapsed"
                                                 ShowGroupPanel="False"
                                                 telerik:StyleManager.Theme="Summer">
                                <telerik:RadGridView.Columns>
                                    <telerik:GridViewDataColumn Width="Auto" Header="a" />
                                    <telerik:GridViewDataColumn Width="*"
                                                                Header="b"
                                                                IsReadOnly="True" />
                                    <telerik:GridViewDataColumn Width="*"
                                                                Header="c"
                                                                IsReadOnly="True"
                                                                TextAlignment="Center" />
                                    <telerik:GridViewDataColumn Width="*"
                                                                Header="d"
                                                                IsReadOnly="True"
                                                                TextAlignment="Center" />
                                    <telerik:GridViewDataColumn Width="*"
                                                                Header="e"
                                                                IsReadOnly="True"
                                                                TextAlignment="Center" />
                                    <telerik:GridViewDataColumn Width="*"
                                                                Header="f"
                                                                IsReadOnly="True"
                                                                TextAlignment="Center" />
                                    <telerik:GridViewDataColumn Width="*"
                                                                Header="g"
                                                                IsReadOnly="True"
                                                                TextAlignment="Center" />
                                    <telerik:GridViewDataColumn Width="*"
                                                                Header="h"
                                                                IsReadOnly="True"
                                                                TextAlignment="Center" />
                                    <telerik:GridViewDataColumn Width="*"
                                                                Header="i"
                                                                IsReadOnly="True"
                                                                TextAlignment="Center" />
                                </telerik:RadGridView.Columns>
                            </telerik:RadGridView>
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
                <telerik:RadSplitContainer InitialPosition="DockedBottom" telerik:ProportionalStackPanel.RelativeSize="250, 750">
                    <telerik:RadPaneGroup FontSize="13" telerik:StyleManager.Theme="Summer">
                        <telerik:RadPane CanUserClose="False" Header="b">
                            <StackPanel Orientation="Vertical">
                                <telerik:RadGridView AutoGenerateColumns="False"
                                                     FontSize="14"
                                                     IsReadOnly="True"
                                                     IsSynchronizedWithCurrentItem="True"
                                                     RowIndicatorVisibility="Collapsed"
                                                     ShowGroupPanel="False"
                                                     telerik:StyleManager.Theme="Summer">
                                    <telerik:RadGridView.Columns>
                                        <telerik:GridViewDataColumn Width="Auto" Header="a" />
                                        <telerik:GridViewDataColumn Width="*" Header="b" />
                                        <telerik:GridViewDataColumn Width="*"
                                                                    Header="c"
                                                                    TextAlignment="Center" />
                                        <telerik:GridViewDataColumn Width="*"
                                                                    Header="d"
                                                                    TextAlignment="Center" />
                                        <telerik:GridViewDataColumn Width="*"
                                                                    Header="e"
                                                                    TextAlignment="Center" />
                                        <telerik:GridViewDataColumn Width="*"
                                                                    Header="f"
                                                                    TextAlignment="Center" />
                                        <telerik:GridViewDataColumn Width="*"
                                                                    Header="g"
                                                                    TextAlignment="Center" />
                                        <telerik:GridViewDataColumn Width="*"
                                                                    Header="h"
                                                                    TextAlignment="Center" />
                                        <telerik:GridViewDataColumn Width="*"
                                                                    Header="i"
                                                                    TextAlignment="Center" />
                                        <telerik:GridViewDataColumn Width="*"
                                                                    Header="j"
                                                                    TextAlignment="Center" />
                                    </telerik:RadGridView.Columns>
                                </telerik:RadGridView>
                            </StackPanel>
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
            </telerik:RadSplitContainer>
        </telerik:RadDocking>
    </Grid>
</UserControl>

Dimitrina
Telerik team
 answered on 10 Feb 2015
2 answers
69 views
Hi,

since my last update the DateTimeContinuousAxis changed the view and I'm confused how to get the old view back.

This is what our X axis looked before: https://dl.dropboxusercontent.com/u/55589036/Pictures/Screenshots/20150108152425.png
And now: https://www.dropbox.com/s/0f961s1on7t0fus/Screenshot%202015-02-09%2015.24.10.png?dl=0

I'm using:             

<telerik:RadCartesianChart.HorizontalAxis>
    <telerik:DateTimeContinuousAxis x:Name="dateTimeContinuousAxis" LabelFitMode="None" LabelFormat="HH:mm:ss" />
</telerik:RadCartesianChart.HorizontalAxis>

Also the new version added space left and right of it, I want to get rid of. I think this connects to my main problem.


How can I solve this to get my old X axis view back?
Martin
Top achievements
Rank 1
 answered on 10 Feb 2015
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?