Telerik Forums
UI for WPF Forum
0 answers
3 views

For several years I have been using the RadDesktopAlertManager in my application. Recently I noticed that it has stopped displaying the alert, but without any exceptions.

When I debug, everything works as expected, until I get to the .ShowAlert execution on the manager. Then this happens.

The rest of my code works just fine, and the only thing I am lacking is the alert... but this is of course an application wide outage.

Any ideas... missing a dll?  or....

hhgm
Top achievements
Rank 1
 asked on 29 Sep 2023
0 answers
5 views

I am setting both the FilterIconBackgroundFiltered and the FilterIconBackground properties on a RadVirtualGrid control in xaml. The FilterIconBackground property changes the filter icon color, but even after adding a filter to a column, the icon never changes to the FilterIconBackgroundFiltered color.

Any thoughts on why this might be happening?

Thanks!


        <tk:RadVirtualGrid x:Name="VirtualGrid"           
            FontSize="{Binding FontSize}"
            Foreground="{Binding RelativeSource={RelativeSource AncestorType={x:Type local:ParticleReportControl}}, Path=Foreground}"
            Background="{StaticResource GsBackgroundDark}"
            CanUserFilterColumns="True"
            CanUserSortColumns="True" 
            ColumnHeaderForeground="{StaticResource GsForegroundMain}"
            ColumnHeaderBackground="{StaticResource GsBackgroundDark2}"
            CellTextAlignment="Center"
            LinesVisibility="Both"
            IsFilterable="True"
            FilterIconBackgroundFiltered="Red"
            FilterIconBackground="{StaticResource GsForegroundMain}"
            HorizontalLinesBrush="{StaticResource GsForegroundMain}"
            VerticalLinesBrush="{StaticResource GsForegroundMain}"
            MeasureTextOnRender="True"
            ShowDistinctFilters="False"
            tk:RadContextMenu.ContextMenu="{StaticResource CtxMenu}"
            CellDecorationsNeeded="VirtualGrid_OnCellDecorationsNeeded"
            HeaderCellDecorationsNeeded="VirtualGrid_OnHeaderCellDecorationsNeeded"
            OverlayBrushesNeeded="VirtualGrid_OnOverlayBrushesNeeded"
            HeaderSizeNeeded="VirtualGrid_HeaderSizeNeeded"
            >
        </tk:RadVirtualGrid>

  
Patrick
Top achievements
Rank 1
 updated question on 29 Sep 2023
2 answers
14 views

When creating a GridViewDataColumn for a RadGridView to use sometimes I want to add custom content for the header in addition to text.


<telerik:RadGridView Grid.Row="2" AutoGenerateColumns="False" >
      <telerik:RadGridView.Items>
          <TextBlock Text="1" />
          <TextBlock Text="2" />
          <TextBlock Text="3" />
      </telerik:RadGridView.Items>
      <telerik:RadGridView.Columns>
         <telerik:GridViewDataColumn Width="80"
                            HeaderTextAlignment="Center"
                            TextAlignment="Center"
                            IsFilterable="False"
                            DataMemberBinding="{Binding Path=Text}">
    <telerik:GridViewDataColumn.Header>
        <Grid>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="*" />
                <ColumnDefinition Width="auto" />
            </Grid.ColumnDefinitions>
            <TextBlock Text="Queued"
                       TextAlignment="Center"
                       VerticalAlignment="Center"
                       ToolTipService.ToolTip="The time elapsed" />
            <Path Grid.Column="1"
                  Data="M22 12C22 17.5228 17.5228 22 12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12ZM12 17.75C12.4142 17.75 12.75 17.4142 12.75 17V11C12.75 10.5858 12.4142 10.25 12 10.25C11.5858 10.25 11.25 10.5858 11.25 11V17C11.25 17.4142 11.5858 17.75 12 17.75ZM12 7C12.5523 7 13 7.44772 13 8C13 8.55228 12.5523 9 12 9C11.4477 9 11 8.55228 11 8C11 7.44772 11.4477 7 12 7Z"
                  Stroke="#1C274C"
                  Width="12"
                  Height="12"
                  Stretch="Fill" />
        </Grid>
    </telerik:GridViewDataColumn.Header>
</telerik:GridViewDataColumn>
      </telerik:RadGridView.Columns>
  </telerik:RadGridView>

The issue is that when the column is sorted the header color is supposed to change to white (I am using the VisualStudio2019Theme)

This behavior breaks when the header is specified in this way so I was wondering what the best way to restore normal behavior is.

Masha
Telerik team
 answered on 27 Sep 2023
0 answers
6 views
Hello Telerik Team,

I'm using RadGridView and having 40+ coulmns in it, out of which almost 20 columns are editable.

It means I'm having controls inside CellTemplate to select or to enter the data.

I want to jump to each control on pressing Tab key.

If I set IsTabStop="False" for the RadGridView, then it jumps as expected. But, I'm not able to jump to the hidden columns behind horizontal scrollbar due to column virtualization is enabled and hence it jumps to the next row.

If I disable the column virtualization, it jumps to the hidden column's control, but horizontal scrollbar is not moving correspondingly.

If I remove the IsTabStop property for the RadGridView and by setting TabStopMode="Skip" for the non editable columns, it jumps to the editable columns correctly and the scrollbar is also moving corresponding to the focus. But, it is not directly focusing on the controls inside CellTemplate, instead it focuses on the Cells on pressing Tab key. I need to press one more time to focus on the control.

Is there any possible way to focus on the control instead of Cell, and the scrollbar also moves correspondingly when the virtualization is on.

Please advise.

Note:
When I tried by setting Column Virtualization off, the performance is very poor as it has more number of columns and rows.


Thanks and Regards,
Muhammad Azhar Shah
Premkumar
Top achievements
Rank 1
Iron
Iron
 asked on 27 Sep 2023
1 answer
12 views

Hello.

I want drag and drop from selected cells to another target cells.

Is it possible move GridView selected string data cells to another cells with drag and drop?

like attached image

Martin Ivanov
Telerik team
 answered on 26 Sep 2023
1 answer
13 views

Hello,

My Radtaskboard contains dozens of items. How do I find an item and scroll to it so the user can find it?
I have made this code:


 foreach (taskboarddata item in MyRadTaskBoard.Items)
 {
     if (item.Id == itemidsearch)
     {
         this.MyRadTaskBoard.SelectedItem = item;


but only selection, the UI does not direct/point to the item.

Thank you for your help.

Dimitar
Telerik team
 answered on 25 Sep 2023
1 answer
6 views
Was wondering if this it is possible to sort based on the value displayed by displaymemberpath on my combobox column. It is populated by a Linq list where I have an ID and then usually a string that is displayed in the column but I only can get it to sort based on the underlying property aka the number and not the string value. Looking for any advice or ideas!
Dimitar
Telerik team
 answered on 25 Sep 2023
1 answer
7 views

Hello,

Can I use any method to clone RadDocument.

Before I`ve used Export -> Import using DocxFormatProvider. But this practic sometime return error (when TrackChange enabled and images were removed, then export ok, but import return MergeBoxNodes Nullreference error).

I just need to clone RadDocument to store second variant without the changes (clone and accept all changes).

Any ideas?

Dimitar
Telerik team
 answered on 25 Sep 2023
0 answers
6 views

Hi, i am creating the below UI,

as seen in the picture below, the thumb is data blind elapsed time, and its working as expected, but i am not able to drag the thumb.

Thanks.

 

n/a
Top achievements
Rank 1
 updated question on 24 Sep 2023
0 answers
8 views

Hi

I have a problem with rendering of the ScheduleView when I change VisibleRange. I use a WeekViewDefinition with a Horizontal orientation. In the handler of the VisibleRangeChangedCommand I replace the content of the binding source of the AppointmentsSource property. When I switch to a new week the new Appointments are not rendered correctly (see screenshot). When I resize my dialog containing the ScheduleView the ScheduleView is updated and rendered correctly.

I started to get this problem when I set the MinTimeRulerExtent property, so that I do not get a scrollbar on my ScheduleView. I guess applying the scrollbar forces an update of the ScheduleView.

Is there a way to force an update after the VisibleRangeChanged event to get the proper rendering?

I use the Windows8 theme and 2021.1.119 version of Telerik WPF components.

Here is the definition of my ScheduleView:

 

<UserControl
    x:Class="Tennotech.Hilding.Watchman.Presentation.Views.Schedules.ScheduleExceptionsDetailsView"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
    xmlns:schedules="clr-namespace:Tennotech.Hilding.Watchman.Presentation.Views.Schedules"
    xmlns:dt="http://tennotech.com/desktop/xaml/2014"
    xmlns:b="http://schemas.microsoft.com/xaml/behaviors"
    mc:Ignorable="d"
    d:DesignHeight="300" d:DesignWidth="300">
    
    <UserControl.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="ScheduleResources.xaml"/>
            </ResourceDictionary.MergedDictionaries>
            
            <telerik:OrientedAppointmentItemStyleSelector x:Key="AppointmentItemStyleSelector"> 
                <telerik:OrientedAppointmentItemStyleSelector.MonthViewStyle> 
                    <Style TargetType="telerik:AppointmentItem" BasedOn="{StaticResource AppointmentItemBaseStyle}"> 
                        <Setter Property="Margin" Value="2 1 2 0" /> 
                        <Setter Property="Background" Value="DarkSlateGray" />
                        <Setter Property="ToolTip" Value="{Binding Appointment.ToolTip}" />
                    </Style> 
                </telerik:OrientedAppointmentItemStyleSelector.MonthViewStyle> 

                <!-- This is the style used by schedules -->
                <telerik:OrientedAppointmentItemStyleSelector.HorizontalStyle> 
                    <Style TargetType="telerik:AppointmentItem" BasedOn="{StaticResource AppointmentItemBaseStyle}">
                        <Setter Property="Margin" Value="0 2 0 10" /> 
                        <Setter Property="Background" Value="#324245" /> 
                        <Setter Property="ToolTip" Value="{Binding Appointment.ToolTip}" />
                    </Style> 
                </telerik:OrientedAppointmentItemStyleSelector.HorizontalStyle>
                
                <telerik:OrientedAppointmentItemStyleSelector.VerticalStyle> 
                    <Style TargetType="telerik:AppointmentItem" BasedOn="{StaticResource AppointmentItemBaseStyle}"> 
                        <Setter Property="Template" Value="{StaticResource AppointmentItemVerticalControlTemplate}"/> 
                        <Setter Property="ResizeCursor" Value="SizeNS"></Setter> 
                        <Setter Property="Margin" Value="1 5 0 5" />
                        <Setter Property="Background" Value="Pink" /> 
                        <Setter Property="ToolTip" Value="{Binding Appointment.ToolTip}" />
                    </Style> 
                </telerik:OrientedAppointmentItemStyleSelector.VerticalStyle> 
            </telerik:OrientedAppointmentItemStyleSelector> 
            
            <DataTemplate x:Key="ToolTipTemplate"> 
                <Grid> 
                    <StackPanel> 
                        <StackPanel Orientation="Horizontal" Margin="0 0 0 0"> 
                            <TextBlock Text="{Binding Start, StringFormat='hh:mm tt'}" TextWrapping="Wrap" FontSize="12" /> 
                            <TextBlock Text=" - " FontSize="10" /> 
                            <TextBlock Text="{Binding End, StringFormat='hh:mm tt'}" TextWrapping="Wrap" FontSize="12" /> 
                        </StackPanel> 
                        <TextBlock Text="{Binding Start, StringFormat='dddd dd MMM yyyy'}" Margin="0 3" FontSize="12" /> 
                    </StackPanel> 
                </Grid> 
            </DataTemplate>
            
            <schedules:ScheduleSlotStyleSelector x:Key="SpecialSlotStyleSelector"> 
                <schedules:ScheduleSlotStyleSelector.ScheduleStyle> 
                    <Style TargetType="telerik:HighlightItem">
                         
                        <Setter Property="Template"> 
                            <Setter.Value> 
                                <ControlTemplate>
                                    <Grid Margin="-2 1 -2 1">
                                        <Border Background="Black"/>
                                        <Border BorderBrush="Gray" BorderThickness="1"/> 
                                    </Grid> 
                                </ControlTemplate> 
                            </Setter.Value> 
                        </Setter> 
                    </Style> 
                </schedules:ScheduleSlotStyleSelector.ScheduleStyle>
                
                <schedules:ScheduleSlotStyleSelector.HistoricStyle> 
                    <Style TargetType="telerik:HighlightItem">
                         
                        <Setter Property="Template"> 
                            <Setter.Value> 
                                <ControlTemplate>
                                    <Grid Margin="-2 1 -2 1">
                                        <Border Background="Transparent"/>
                                        <Border BorderBrush="Gray" BorderThickness="1"/> 
                                    </Grid> 
                                </ControlTemplate> 
                            </Setter.Value> 
                        </Setter> 
                    </Style> 
                </schedules:ScheduleSlotStyleSelector.HistoricStyle> 

            </schedules:ScheduleSlotStyleSelector> 
            
        </ResourceDictionary>
    </UserControl.Resources>

    <Grid>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="*"/>
            <ColumnDefinition Width="Auto"/>
        </Grid.ColumnDefinitions>

        <!--
        SpecialSlotStyleSelector="{StaticResource SpecialSlotStyleSelector}"
        MouseOverHighlightStyle="{StaticResource MouseOverHighlightStyle}"
        SelectionHighlightStyle="{StaticResource SelectionHighlightStyle}"
        -->
        
        <telerik:RadScheduleView
            x:Name="ScheduleView"
            AppointmentsSource="{Binding Appointments}"
            VisibleRangeChangedCommand="{Binding VisibleRangeChangedCommand}"
            VisibleRangeChangedCommandParameter="{Binding VisibleRange, RelativeSource={RelativeSource Self}}"
            CurrentDate="{Binding CurrentDate, Mode=TwoWay}"
            SnapAppointments="True"
            TodayButtonVisibility="Hidden"
            IsInlineEditingEnabled="False"
            NavigationHeaderVisibility="Visible"
            SpecialSlotsSource="{Binding SpecialSlots}"
            FirstVisibleTime="0:00"
            ResourceTypesSource="{Binding ResourceTypes}"
            AppointmentStyleSelector="{StaticResource AppointmentItemStyleSelector}"
            GroupHeaderStyleSelector="{StaticResource SchemaGroupHeaderStyleSelector}"
            GroupHeaderContentTemplateSelector="{StaticResource SchemaGroupHeaderContentTemplateSelector}"
            ToolTipTemplate="{StaticResource ToolTipTemplate}"
            SpecialSlotStyleSelector="{StaticResource SpecialSlotStyleSelector}"
            MinTimeRulerExtent="200"
            >
            <!--
            MinTimeRulerExtent="200"
             -->
            
            <b:Interaction.Behaviors>
                <schedules:PreventCloseDialogBehavior/>
                <schedules:PreventAddScheduleDialogException/>
                <schedules:FastAppointmentAddBehavior Appointments="{Binding Appointments}"/>
                <schedules:FilterAppointmentsBehavior/>
            </b:Interaction.Behaviors>
            
            <telerik:RadScheduleView.DragDropBehavior> 
                <schedules:ScheduleDragDropBehavior />
            </telerik:RadScheduleView.DragDropBehavior>
            <telerik:RadScheduleView.SlotSelectionBehavior> 
                <schedules:ScheduleSlotSelectionBehavior/> 
            </telerik:RadScheduleView.SlotSelectionBehavior> 

            <telerik:RadScheduleView.ActiveViewDefinition>
                <telerik:WeekViewDefinition
                    TimerulerMajorTickStringFormat="{}{0:%H}:{0:mm}"
                    ShowWeekGroupHeaders="False"
                    MinorTickLength="15min"
                    Orientation="Horizontal"
                    StretchGroupHeaders="True"
                    FirstDayOfWeek="Monday"
                    VisibleDays="7" />
                
            </telerik:RadScheduleView.ActiveViewDefinition>

            <telerik:RadScheduleView.GroupDescriptionsSource>
                <telerik:GroupDescriptionCollection>
                    <telerik:DateGroupDescription/>
                    <telerik:ResourceGroupDescription ResourceType="Schedules" />
                </telerik:GroupDescriptionCollection>
            </telerik:RadScheduleView.GroupDescriptionsSource>
        </telerik:RadScheduleView>
        
        <DockPanel Grid.Column="1" Margin="20 0 0 0" MinWidth="300">
            <TextBlock Text="{dt:Text ScheduleExceptions}" DockPanel.Dock="Top" Style="{StaticResource Title}"/>

            <telerik:RadGridView
                x:Name="ScheduleGrid"
                DockPanel.Dock="Bottom"
                ItemsSource="{Binding ScheduleExceptions}"
                AutoExpandGroups="True"
                AutoGenerateColumns="False"
                CanUserFreezeColumns="False"
                CanUserReorderColumns="False"
                CanUserSelect="True"
                EnableRowVirtualization="True"
                GroupRenderMode="Flat"
                IsReadOnly="True"
                RowIndicatorVisibility="Collapsed"
                SelectionMode="Single"
                SelectionUnit="FullRow"
                ShowGroupPanel="False"
                dt:CommandBindingsBehavior.RegisterCommandBindings="{Binding CommandBindings}">
                
                <b:Interaction.Behaviors>
                    <schedules:RowDoubleClickBehavior Command="{Binding RowDoubleClickedCommand}"/>
                </b:Interaction.Behaviors>
                
                <!--
                <b:Interaction.Triggers>
                    <b:EventTrigger EventName="RowActivated" >
                        <b:InvokeCommandAction Command="{Binding RowActivatedCommand}" />
                    </b:EventTrigger>
                </b:Interaction.Triggers>
                -->
                
                <telerik:RadGridView.Columns>
                    <telerik:GridViewDataColumn
                        SortingState="Ascending"
                        DataMemberBinding="{Binding Start}"
                        Header="{dt:Text Start}" />
                    
                    <telerik:GridViewDataColumn
                        IsSortable="False"
                        DataMemberBinding="{Binding End}"
                        Header="{dt:Text End}" />
                    
                    <telerik:GridViewDataColumn
                        IsSortable="False"
                        DataMemberBinding="{Binding IsActive}"
                        Header="{dt:Text IsActive}" />
                    
                    <telerik:GridViewColumn
                        Header="Delete"
                        IsSortable="False"> 
                        <telerik:GridViewColumn.CellTemplate> 
                            <DataTemplate> 
                                <telerik:RadButton
                                    Content="Delete"
                                    Command="telerik:RadGridViewCommands.Delete"
                                    CommandParameter="{Binding}" /> 
                            </DataTemplate> 
                        </telerik:GridViewColumn.CellTemplate> 
                    </telerik:GridViewColumn> 
                </telerik:RadGridView.Columns>
            </telerik:RadGridView>
        </DockPanel>
        
    </Grid>
</UserControl>

Ola
Top achievements
Rank 1
 asked on 22 Sep 2023
Narrow your results
Selected tags
Tags
+? more
Top users last month
Stephan
Top achievements
Rank 2
Veteran
Iron
Stefan
Top achievements
Rank 1
Iron
tar
Top achievements
Rank 2
Iron
Iron
Iron
Tibor
Top achievements
Rank 1
Pascal
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Stephan
Top achievements
Rank 2
Veteran
Iron
Stefan
Top achievements
Rank 1
Iron
tar
Top achievements
Rank 2
Iron
Iron
Iron
Tibor
Top achievements
Rank 1
Pascal
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?