Telerik Forums
UI for WPF Forum
1 answer
145 views
I have a button inside a RowDetailsTemplate. Hover and click events don't flow to the button, but result in the selection of the row. Is this normal? How can I make my button handle them instead? My button extends from the WPF Button class, so I'd assume it already has handlers and such...
Vlad
Telerik team
 answered on 23 Mar 2011
6 answers
365 views
Hi,

I've a problem, I don't know if it's a bug, but it's blocking for me:

I've a Window, which provides some ObservableCollection to my users controls through binding

in my user control, I've a RadGridView which is bound on a property of my code behind. This property use objects issued from the binding with the window.

I've a collection of objects which is displayed.

The problem is:

I'm now trying to add a GridViewComboBoxColumn, but if I put a converter on itemsource only to see which context I've:
<telerik:GridViewComboBoxColumn Header="Channel"  DataMemberBinding="{Binding Channel}" ItemsSource="{Binding  Converter={StaticResource Watcher}}" Width="2*"/>

I get the context of the Window!

Why??? This should be the datacontext of the usercontrol!

I double checked, In my code behind of my code behind, I've never any reference of the window, or somewhere where I could have bound the datacontext to the window?

I've a "theGridName.DataContext = this;" in the userControl's code behind, nothing else.

Thank you for your help
Julien
Top achievements
Rank 1
 answered on 23 Mar 2011
1 answer
145 views
How can render time of a complex RadGridView with templates be performed to find bottlenecks? 
Vlad
Telerik team
 answered on 23 Mar 2011
3 answers
266 views

I am currently evaluating the RadGridView and would like to know how customizable the column headers are.

Could someone please take a look at at the attached picture and let me know if it is possible to achieve the type of header customization shown there?

Thanks.
Maya
Telerik team
 answered on 23 Mar 2011
9 answers
250 views
Hi

When moving around undocked RadPanes, I am seeing very high CPU usage - around 70% according to the Windows Task Manager. My app is a very basic one with some RadDocking controls, and very little else - almost no procedural code. My CPU is a Core2Duo E6750, and my GFX card is a GeForce GTS450. When I drag the main window around, the CPU only jumps to around 10%. I'm running a release build.

Any idea why I'm seeing such high CPU usage? Could I be doing something wrong?

For reference, doing the same thing in the Telerik Demo app causes a CPU usage of about 35% - so about half what my own app takes, but still very high for such a basic operation.


Thanks
Tom Davies
Peavey Digital Research
Miroslav Nedyalkov
Telerik team
 answered on 23 Mar 2011
2 answers
105 views
Hi ,
I am trying to display hiearchial data in the gridview . Please see the attached screenshot .
The parent level can have multiple child elements which themselves can be hiearchial.
I have used ChildTableDefinition and HiearchyChildTemplate, but how do I specify different HieararchyChildTemplate for different subitems ?
Subarna Bandyopadhya
Top achievements
Rank 1
 answered on 22 Mar 2011
5 answers
253 views
Hi,

I want to customize the Appointment Item. Therefore I proceeded as described in http://www.telerik.com/help/wpf/radscheduleview-styles-and-templates-appointment-style.html. But after creating the AppointmentStyleSelector nothing happens when I doubleclick an appointment. What went wrong? Are there any triggers missing? Below is the XAML which was generated by Expression Blend (4). I'm using Q1 2011 telerik controls.

thanks in advance,

michael


<telerik:OrientedAppointmentItemStyleSelector x:Key="AppointmentStyleSelector">
          <telerik:OrientedAppointmentItemStyleSelector.HorizontalStyle>
              <Style TargetType="{x:Type telerik:AppointmentItem}">
                  <Setter Property="Margin" Value="0,1,0,0"/>
                  <Style.BasedOn>
                      <Style TargetType="{x:Type telerik:AppointmentItem}">
                          <Setter Property="Background">
                              <Setter.Value>
                                  <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                      <GradientStop Color="White"/>
                                      <GradientStop Color="#FFD4D4D4" Offset="1"/>
                                  </LinearGradientBrush>
                              </Setter.Value>
                          </Setter>
                          <Setter Property="BorderBrush" Value="#FF848484"/>
                          <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
                          <Setter Property="VerticalContentAlignment" Value="Stretch"/>
                          <Setter Property="Foreground" Value="Black"/>
                          <Setter Property="BorderThickness" Value="1"/>
                          <Setter Property="Padding" Value="2,0,0,0"/>
                          <Setter Property="Focusable" Value="True"/>
                          <Setter Property="ContentTemplateSelector">
                              <Setter.Value>
                                  <telerik:AppointmentItemContentTemplateSelector>
                                      <telerik:AppointmentItemContentTemplateSelector.DefaultTemplate>
                                          <DataTemplate>
                                              <TextBlock TextWrapping="Wrap" Text="{Binding Subject}" TextTrimming="WordEllipsis"/>
                                          </DataTemplate>
                                      </telerik:AppointmentItemContentTemplateSelector.DefaultTemplate>
                                  </telerik:AppointmentItemContentTemplateSelector>
                              </Setter.Value>
                          </Setter>
                          <Setter Property="Template">
                              <Setter.Value>
                                  <ControlTemplate TargetType="{x:Type telerik:AppointmentItem}">
                                      <Grid x:Name="Root">
                                          <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" CornerRadius="2">
                                              <Border BorderBrush="White" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1"/>
                                          </Border>
                                          <Border x:Name="CommonStatesVisual" BorderBrush="#FFFFC92B" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2" Visibility="Collapsed">
                                              <Border.Background>
                                                  <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                      <GradientStop Color="#FFFFFBA3" Offset="1"/>
                                                      <GradientStop Color="#FFFFFBDA" Offset="0"/>
                                                  </LinearGradientBrush>
                                              </Border.Background>
                                              <Border x:Name="CommonStatesVisualInnerBorder" BorderBrush="White" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1"/>
                                          </Border>
                                          <Border x:Name="PART_Category" Background="{Binding Category.CategoryBrush}" Margin="2"/>
                                          <Rectangle x:Name="ReadOnlyVisual" Fill="#B2BABFC6" Margin="2" Visibility="Collapsed"/>
                                          <Grid Margin="2">
                                              <Grid.ColumnDefinitions>
                                                  <ColumnDefinition Width="Auto"/>
                                                  <ColumnDefinition Width="Auto"/>
                                                  <ColumnDefinition Width="*"/>
                                              </Grid.ColumnDefinitions>
                                              <Border x:Name="PART_TimeMarker" Background="{Binding TimeMarker.TimeMarkerBrush}" Grid.Column="0" HorizontalAlignment="Left" Width="5">
                                                  <Border.Visibility>
                                                      <Binding Path="TimeMarker">
                                                          <Binding.Converter>
                                                              <telerik:NullToVisibilityConverter/>
                                                          </Binding.Converter>
                                                      </Binding>
                                                  </Border.Visibility>
                                              </Border>
                                              <StackPanel Grid.Column="1" Margin="0,3,0,0" VerticalAlignment="Top">
                                                  <Image x:Name="RecurrenceMark" Grid.Column="0" HorizontalAlignment="Left" Height="10" Margin="2,1,1,0" Width="10">
                                                      <Image.Source>
                                                          <BitmapImage UriSource="pack://application:,,,/Telerik.Windows.Controls.ScheduleView;component/Themes/Images/AppointmentException.png"/>
                                                      </Image.Source>
                                                      <Image.Visibility>
                                                          <Binding Path="RecurrenceState">
                                                              <Binding.Converter>
                                                                  <telerik:RecurrenceStateIsExeptionToVisibilityConverter/>
                                                              </Binding.Converter>
                                                          </Binding>
                                                      </Image.Visibility>
                                                  </Image>
                                                  <Image x:Name="ExceptionMark" Grid.Column="0" HorizontalAlignment="Left" Height="10" Margin="2,1,1,0" Width="10">
                                                      <Image.Source>
                                                          <BitmapImage UriSource="pack://application:,,,/Telerik.Windows.Controls.ScheduleView;component/Themes/Images/AppointmentRecurrence.png"/>
                                                      </Image.Source>
                                                      <Image.Visibility>
                                                          <Binding Path="RecurrenceState">
                                                              <Binding.Converter>
                                                                  <telerik:RecurrenceStateIsOccurenceToVisibilityConverter/>
                                                              </Binding.Converter>
                                                          </Binding>
                                                      </Image.Visibility>
                                                  </Image>
                                              </StackPanel>
                                              <ContentPresenter ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" Grid.Column="2" ContentStringFormat="{TemplateBinding ContentStringFormat}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                                          </Grid>
                                          <Grid x:Name="MouseOverOverlay" Opacity="0" Visibility="Collapsed">
                                              <Border x:Name="PART_StartResizeGrip" telerik:RadDragAndDropManager.AllowDrag="True" Background="Transparent" Cursor="SizeWE" HorizontalAlignment="Left" VerticalAlignment="Stretch">
                                                  <StackPanel x:Name="StartResizeGrip" HorizontalAlignment="Center" Margin="1" VerticalAlignment="Center">
                                                      <Border BorderBrush="#FF444444" BorderThickness="0,0,1,1" Background="White" Height="3" Margin="1" Width="3"/>
                                                      <Border BorderBrush="#FF444444" BorderThickness="0,0,1,1" Background="White" Height="3" Margin="1" Width="3"/>
                                                      <Border BorderBrush="#FF444444" BorderThickness="0,0,1,1" Background="White" Height="3" Margin="1" Width="3"/>
                                                  </StackPanel>
                                              </Border>
                                              <Border x:Name="PART_EndResizeGrip" telerik:RadDragAndDropManager.AllowDrag="True" Background="Transparent" Cursor="SizeWE" HorizontalAlignment="Right" VerticalAlignment="Stretch">
                                                  <StackPanel x:Name="EndResizeGrip" HorizontalAlignment="Center" Margin="1" VerticalAlignment="Center">
                                                      <Border BorderBrush="#FF444444" BorderThickness="0,0,1,1" Background="White" Height="3" Margin="1" Width="3"/>
                                                      <Border BorderBrush="#FF444444" BorderThickness="0,0,1,1" Background="White" Height="3" Margin="1" Width="3"/>
                                                      <Border BorderBrush="#FF444444" BorderThickness="0,0,1,1" Background="White" Height="3" Margin="1" Width="3"/>
                                                  </StackPanel>
                                              </Border>
                                              <telerik:RadButton x:Name="DeleteButton" CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" Command="telerik:RadScheduleViewCommands.DeleteAppointment" HorizontalAlignment="Right" Height="11" Margin="5" Padding="0" VerticalAlignment="Top" Width="11">
                                                  <telerik:StyleManager.Theme>
                                                      <telerik:Office_BlackTheme/>
                                                  </telerik:StyleManager.Theme>
                                                  <Path Data="M0,0L5,5 M5,0L0,5" Stroke="#FF444444"/>
                                              </telerik:RadButton>
                                          </Grid>
                                      </Grid>
                                      <ControlTemplate.Triggers>
                                          <MultiTrigger>
                                              <MultiTrigger.Conditions>
                                                  <Condition Property="IsReadOnly" Value="True"/>
                                                  <Condition Property="IsEnabled" Value="True"/>
                                              </MultiTrigger.Conditions>
                                              <Setter Property="Visibility" TargetName="ReadOnlyVisual" Value="Visible"/>
                                          </MultiTrigger>
                                          <MultiTrigger>
                                              <MultiTrigger.Conditions>
                                                  <Condition Property="IsReadOnly" Value="False"/>
                                                  <Condition Property="IsMouseOver" Value="True"/>
                                                  <Condition Property="IsEnabled" Value="True"/>
                                              </MultiTrigger.Conditions>
                                              <MultiTrigger.EnterActions>
                                                  <BeginStoryboard>
                                                      <Storyboard>
                                                          <ObjectAnimationUsingKeyFrames Duration="0:0:0.4" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="MouseOverOverlay">
                                                              <DiscreteObjectKeyFrame KeyTime="0">
                                                                  <DiscreteObjectKeyFrame.Value>
                                                                      <Visibility>Visible</Visibility>
                                                                  </DiscreteObjectKeyFrame.Value>
                                                              </DiscreteObjectKeyFrame>
                                                          </ObjectAnimationUsingKeyFrames>
                                                          <DoubleAnimation BeginTime="0:0:0.2" Duration="0:0:0.2" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="MouseOverOverlay"/>
                                                      </Storyboard>
                                                  </BeginStoryboard>
                                              </MultiTrigger.EnterActions>
                                              <MultiTrigger.ExitActions>
                                                  <BeginStoryboard>
                                                      <Storyboard>
                                                          <ObjectAnimationUsingKeyFrames Duration="0:0:0.2" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="MouseOverOverlay">
                                                              <DiscreteObjectKeyFrame KeyTime="0:0:0.2">
                                                                  <DiscreteObjectKeyFrame.Value>
                                                                      <Visibility>Collapsed</Visibility>
                                                                  </DiscreteObjectKeyFrame.Value>
                                                              </DiscreteObjectKeyFrame>
                                                          </ObjectAnimationUsingKeyFrames>
                                                          <DoubleAnimation BeginTime="0" Duration="0:0:0.2" To="0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="MouseOverOverlay"/>
                                                      </Storyboard>
                                                  </BeginStoryboard>
                                              </MultiTrigger.ExitActions>
                                              <Setter Property="Visibility" TargetName="CommonStatesVisual" Value="Visible"/>
                                              <Setter Property="Visibility" TargetName="MouseOverOverlay" Value="Visible"/>
                                          </MultiTrigger>
                                          <Trigger Property="IsSelected" Value="True">
                                              <Setter Property="Visibility" TargetName="CommonStatesVisual" Value="Visible"/>
                                              <Setter Property="Background" TargetName="CommonStatesVisual">
                                                  <Setter.Value>
                                                      <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                          <GradientStop Color="#FFFCE79F" Offset="1"/>
                                                          <GradientStop Color="#FFFDD3A8"/>
                                                      </LinearGradientBrush>
                                                  </Setter.Value>
                                              </Setter>
                                              <Setter Property="BorderBrush" TargetName="CommonStatesVisual" Value="#FFFFC92B"/>
                                              <Setter Property="BorderBrush" TargetName="CommonStatesVisualInnerBorder" Value="White"/>
                                          </Trigger>
                                      </ControlTemplate.Triggers>
                                  </ControlTemplate>
                              </Setter.Value>
                          </Setter>
                          <Setter Property="Panel.ZIndex" Value="1"/>
                      </Style>
                  </Style.BasedOn>
              </Style>
          </telerik:OrientedAppointmentItemStyleSelector.HorizontalStyle>
Michael
Top achievements
Rank 1
 answered on 22 Mar 2011
3 answers
209 views
Depending on how I have set up my combobox, I can detect when a user selects an item.  Either the property I have bound to SelectedItem changes, or the SelectionChanged event fires.
But neither of these occur if the user selects the same item again.

Any ideas of how I can detect this?
Buzz
Valeri Hristov
Telerik team
 answered on 22 Mar 2011
3 answers
1.0K+ views
Hi,

I'm trying to use this control for user management, I am aware that you're not supposed to bind to PasswordBox field, and I do not intend to, but I would like to have the field there when you're going to insert a new user or edit a current user (in the case of edit it would be an empty text field).

How would you go about achieving this?

Thanks,
Daryl
Vanya Pavlova
Telerik team
 answered on 22 Mar 2011
3 answers
99 views
Hi 

Is following possible with telerik wpf richtextbox? Allowing only parts of document to be updateable?

http://office.microsoft.com/en-us/help/allow-changes-to-parts-of-a-protected-document-HP010082301.aspx

Thanks!

Nodir Yuldashev
Ivailo Karamanolev
Telerik team
 answered on 22 Mar 2011
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?