Target Application : WPF
.Net Framework : 4.6.2
Telerik Version : 2017.2.503.45 (Telerik.Windows.Controls)
Hi
We are using RadBusyIndicator control for the client application, which raising the bellow exception randmoly on Production for long time.
Unfortunately it is not reproducible in development environment.
But as per the AppInsight log, assuming that happens on StoaryBoard animation as highlighted in the below style code.
Collection was modified; enumeration operation may not execute.
Type: System.InvalidOperationException
Message: Collection was modifined; enumeration operation may not execute.
Source:mscrolib
Help link:
Data: System.Collection.ListDictionaryInternal
TargetSite: System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource)
Stack Trace: at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource)
at System.Collections.Generic.List`1.Enumerator.MoveNextRare()
at Telerik.Windows.Controls.Animation.AnimationManager.InvkokeCallbacks(Storyboard storyboard)
at Telerik.Windows.Controls.Animation.AnimationManager.OnStoryboardCompleted(Object sender, EventArgs e)
at System.Windows.Media.Animation.Clock.FireEvent(EventPrivateKey key)
at System.Windows.Media.Animation.Clock.RaiseAccumulatedEvents()
at System.Windows.Media.Animation.TimeManager.RaiseEnqueuedEvents()
at System.Windows.Media.Animation.TimeManager.Tick()
at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)
at System.Windows.Media.MediaContext.AnimatedRenderMessageHandler(Object resizedCompositionTarget)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)And following is the style used for the busy indicator. There is no clue to find the root cause except this exception log.
<Style x:Key="RadBusyIndicatorStyle"
TargetType="{x:Type telerik:RadBusyIndicator}">
<Setter Property="BusyContent"
Value="Loading..." />
<Setter Property="IsTabStop"
Value="False" />
<Setter Property="DisplayAfter"
Value="0:0:0.1" />
<Setter Property="BorderBrush"
Value="#FFD0D0D0" />
<Setter Property="Background">
<Setter.Value>
<LinearGradientBrush EndPoint="0.5,1"
StartPoint="0.5,0">
<GradientStop Color="White"
Offset="0" />
<GradientStop Color="#A9DCDADA"
Offset="1" />
</LinearGradientBrush>
</Setter.Value>
</Setter>
<Setter Property="BorderThickness"
Value="1" />
<Setter Property="ProgressBarStyle">
<Setter.Value>
<Style TargetType="{x:Type telerik:RadProgressBar}">
<Setter Property="Margin"
Value="15,15,15,5" />
<Setter Property="IsIndeterminate"
Value="True" />
<Setter Property="Maximum"
Value="100" />
<Setter Property="Orientation"
Value="Horizontal" />
<Setter Property="IsTabStop"
Value="False" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type telerik:RadProgressBar}">
<Grid>
<Path x:Name="IndeterminateBackgroundDonut"
Height="44"
RenderTransformOrigin="0.5,0.5"
Stroke="#FF133E80"
Width="44">
<Path.Data>
<GeometryGroup FillRule="EvenOdd">
<EllipseGeometry Center="22,22"
RadiusY="20"
RadiusX="20" />
<EllipseGeometry Center="22,22"
RadiusY="14"
RadiusX="14" />
</GeometryGroup>
</Path.Data>
<Path.Fill>
<RadialGradientBrush>
<GradientStop Color="#FF224272"
Offset="0" />
<GradientStop Color="#FF224272"
Offset="0.921" />
<GradientStop Color="#FFC8DCFB"
Offset="0.254" />
<GradientStop Color="#FF335A95"
Offset="0.877" />
</RadialGradientBrush>
</Path.Fill>
</Path>
<Path x:Name="IndeterminateDonut"
Height="44"
RenderTransformOrigin="0.5,0.5"
Visibility="Collapsed"
Width="44">
<Path.Data>
<GeometryGroup FillRule="EvenOdd">
<EllipseGeometry Center="22,22"
RadiusY="20"
RadiusX="20" />
<EllipseGeometry Center="22,22"
RadiusY="14"
RadiusX="14" />
</GeometryGroup>
</Path.Data>
<Path.Fill>
<RadialGradientBrush Center="0.5,-0.23"
GradientOrigin="0.8,0.25"
RadiusY="0.68"
RadiusX="0.68">
<GradientStop Color="#BFFFFFFF"
Offset="0" />
<GradientStop Color="Transparent"
Offset="1" />
<GradientStop Color="#21FFFFFF"
Offset="0.65" />
</RadialGradientBrush>
</Path.Fill>
<Path.RenderTransform>
<RotateTransform />
</Path.RenderTransform>
</Path>
<Grid x:Name="ProgressBarTrack"
Height="24"
RenderTransformOrigin="0.5,0.5"
Width="24">
<Grid.Clip>
<EllipseGeometry Center="12,12"
RadiusY="12"
RadiusX="12" />
</Grid.Clip>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RenderTransform>
<RotateTransform Angle="-90" />
</Grid.RenderTransform>
<Rectangle x:Name="SkipValueSpacer" />
<Rectangle x:Name="ProgressBarIndicator"
Grid.Column="1">
<Rectangle.Fill>
<RadialGradientBrush>
<GradientStop Color="#FFCCCCCC"
Offset="1" />
<GradientStop Color="White" />
</RadialGradientBrush>
</Rectangle.Fill>
</Rectangle>
</Grid>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsIndeterminate"
Value="True">
<Trigger.EnterActions>
<BeginStoryboard x:Name="MouseOverStoryboard_BeginStoryboard">
<Storyboard RepeatBehavior="Forever">
<DoubleAnimationUsingKeyFrames BeginTime="0"
Storyboard.TargetProperty="(UIElement.RenderTransform).(RotateTransform.Angle)"
Storyboard.TargetName="IndeterminateDonut">
<SplineDoubleKeyFrame KeyTime="0:0:1"
Value="360" />
</DoubleAnimationUsingKeyFrames>
</Storyboard>
</BeginStoryboard>
</Trigger.EnterActions>
<Trigger.ExitActions>
<StopStoryboard BeginStoryboardName="MouseOverStoryboard_BeginStoryboard" />
</Trigger.ExitActions>
<Setter Property="Visibility"
TargetName="IndeterminateDonut"
Value="Visible" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</Setter.Value>
</Setter>
<Setter Property="Telerik_Windows_Controls_Animation:AnimationManager.AnimationSelector">
<Setter.Value>
<Telerik_Windows_Controls_Animation:AnimationSelector>
<Telerik_Windows_Controls_Animation:FadeAnimation AnimationName="Hide"
Direction="Out"
Easing="{x:Null}"
MaxOpacity="1"
MinOpacity="0"
SpeedRatio="0"
TargetElementName="Indicator" />
<Telerik_Windows_Controls_Animation:FadeAnimation AnimationName="Show"
Direction="In"
Easing="{x:Null}"
MaxOpacity="1"
MinOpacity="0"
SpeedRatio="0"
TargetElementName="Indicator" />
</Telerik_Windows_Controls_Animation:AnimationSelector>
</Setter.Value>
</Setter>
<Setter Property="OverlayStyle">
<Setter.Value>
<Style TargetType="{x:Type Rectangle}">
<Setter Property="Fill"
Value="#88FFFFFF" />
</Style>
</Setter.Value>
</Setter>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type telerik:RadBusyIndicator}">
<Grid Background="{TemplateBinding Background}">
<ContentControl x:Name="Content"
ContentTemplate="{TemplateBinding ContentTemplate}"
Content="{TemplateBinding Content}"
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
IsEnabled="False"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="{TemplateBinding IsTabStop}"/>
<Rectangle x:Name="Overlay"
Style="{TemplateBinding OverlayStyle}" />
<Border x:Name="Indicator"
BorderThickness="{TemplateBinding BorderThickness}"
CornerRadius="2"
HorizontalAlignment="Center"
MinWidth="180"
VerticalAlignment="Center"
Background="#FFBCBCBC"
BorderBrush="#FF254474"
SnapsToDevicePixels="True">
<StackPanel>
<telerik:RadProgressBar x:Name="ProgressBar"
IsIndeterminate="{TemplateBinding IsIndeterminate}"
Maximum="100"
Style="{TemplateBinding ProgressBarStyle}"
Value="{TemplateBinding ProgressValue}" />
<ContentPresenter ContentTemplate="{TemplateBinding BusyContentTemplate}"
Content="{TemplateBinding BusyContent}"
HorizontalAlignment="Center"
Margin="15,5,15,15"/>
</StackPanel>
</Border>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsBusyIndicationVisible"
Value="False">
<Setter Property="Visibility"
TargetName="Indicator"
Value="Collapsed" />
<Setter Property="Visibility"
TargetName="Overlay"
Value="Collapsed" />
<Setter Property="IsIndeterminate"
TargetName="ProgressBar"
Value="False" />
<Setter Property="IsEnabled"
TargetName="Content"
Value="True" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
Any suggestion? And thanks in advance!
I am using a RadCardView for the first time, and nothing is displaying. I have followed the online sample code, and even replaced the Rad Card View with a list box to make sure the bindings are working, and still nothing appears to be displaying in the area where the CardView (previously a list box) should display. Here is part of my code:
<telerik:RadCardView x:Name="cardView" Margin="5"Hi:
How can I set the data Form to show required fields validation message based on annotations to appear on the right of the field like this image;

i am trying to custom style RadNumericUpDown control but every time i try to click right and edit control i am losing focus
tried to find the template in documentation to copy , paste and then edit, however i couldn't
can you help with this please?
Best
Hello,
is it possible to manipulate or clear the navigation history of the explorer control?
Best regards,
Philipp

Hi
I have created a behavior for quickly adding appointments on mouse up.
I have currently been using the SelectedSlot (Start/End) property of RadScheduleView to create an appointment, but now I discovered that when selecting with Alt-key down you can get the same Start/End selected over multiple days. When debugging I can see these intervals in the Slot.Infos property, but this property is internal so I can't access it.
Is there another way to find these intervals in the RadScheduleView?
Hey i dont want to use the integrated version of the Searchpanel because my design has it a different possition than direktly above it.
So i want to use <telerik:GridViewSearchPanel /> but i dont know how to bind it to the RadGridView.
Thanks
Dominik

Hi,
I'm trying to debug the salesdashboard source and receive the following error? Not sure how to resolve, can someone help please?
System.Data.Services.Client.DataServiceQueryException
HResult=0x80131509
Message=An error occurred while processing this request.
Source=Microsoft.Data.Services.Client
StackTrace:
at System.Data.Services.Client.QueryResult.EndExecuteQuery[TElement](Object source, String method, IAsyncResult asyncResult)
at System.Data.Services.Client.DataServiceRequest.EndExecute[TElement](Object source, DataServiceContext context, String method, IAsyncResult asyncResult)
at System.Data.Services.Client.DataServiceQuery`1.EndExecute(IAsyncResult asyncResult)
at SalesDashboard.MainRepository.<>c__DisplayClass22_1.<GetDailyActualsVsTargetsByProduct>b__1() in C:\Users\robertf\Downloads\SalesDashboard_WPF_Dev_2023_3_1114_SourceCode\SalesDashboard\ViewModel\MainRepository.cs:line 126
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
This exception was originally thrown at this call stack:
[External Code]
Inner Exception 1:
DataServiceClientException: <?xml version="1.0" encoding="utf-8" standalone="yes"?>
<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">
<code></code>
<message xml:lang="en-US">An error occurred while processing this request.</message>
</error>

Hi,
We have an old application (VB6) that we are migrating to WPF and .NET 8. I use your WPF controls in this application. We use this application to creat test templates for different instruments.
Each test template consists of one or more subtest templates. Each subtest template consists of a test grid with different number of rows and columns, depending of instrument and type of test.
The subtest template grids data is stored in a database. Each subtest are stored in one table, each column number is stored in one table with foreign key to the subtest table, each cells value and row number is stored in one table with foreign key to the column table.
So far I have managed read data to my gridview with the help of your article https://docs.telerik.com/devtools/wpf/controls/radgridview/how-to/use-mixed-clr-dlr-properties.
First question,
I want the 4 first rows to be comboboxes, different combobox data for each row. I have been able to get comboboxes with DataTempletSelector, DataTemplate and RadGridView_AutoGeneratingColumn,
with help from this forum post from Petar Mladenov https://www.telerik.com/forums/unable-to-use-datatemplates-with-gridview-dynamic-data-not-even-with-icustomtypeprovider.
But my problem is that I don't get any data in the comboboxes. So how should I define my combobox so it databinds to my collection of comboboxdata?
Second question,
If I manage to fill the comboxes with data I don't know how to databind selectedvalue to my ObservableCollection<MyDataRow>, so how can I do that?
The rest of the gridcells are textboxes and they databinds automatically and updates my ObservableCollection<MyDataRow> when I change a value in a cell.
This is my gridview,
<telerik:RadGridView x:Name="TestCasesGridView"
ItemsSource="{Binding SubtestTestCases, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged, BindsDirectlyToSource=True}"
IsFilteringAllowed="False"
CanUserSortColumns="False"
ShowColumnHeaders="True"
ShowSearchPanel="True"
SearchMode="MatchAllTerms"
SearchPanelCloseButtonVisibility="Collapsed"
IsSynchronizedWithCurrentItem="False"
AutoGenerateColumns="True"
AutoGeneratingColumn="RadGridView_AutoGeneratingColumn"
Margin="10"
IsReadOnly="False"
ShowGroupPanel="False"
RowIndicatorVisibility="Collapsed"
Height="Auto"
Width="Auto"
ScrollMode="Deferred"
ClipboardCopyMode="Default"
ClipboardPasteMode="AllSelectedRows"
SelectionMode="Single"
SelectionUnit="FullRow"
ScrollViewer.HorizontalScrollBarVisibility="Auto"
ScrollViewer.VerticalScrollBarVisibility="Auto"
CanUserSelectColumns ="False"
GroupRenderMode="Flat">
<telerik:RadGridView.Columns>
<helper:MyColumn Header="#"
Width="30" TextAlignment="Center"/>
</telerik:RadGridView.Columns>
<telerik:RadGridView.Resources>
<helper:MyCellTemplateSelector x:Key="myCellTemplateSelector">
<helper:MyCellTemplateSelector.ColumnNames>
<DataTemplate>
<telerik:RadComboBox ItemsSource="{Binding ColumnNames}" DisplayMemberPath="KBE_Ben" OpenDropDownOnFocus="True"/>
</DataTemplate>
</helper:MyCellTemplateSelector.ColumnNames>
<helper:MyCellTemplateSelector.ColumnUnit>
<DataTemplate>
<telerik:RadComboBox ItemsSource="{Binding ColumnUnits}" DisplayMemberPath="KEN_Kod" OpenDropDownOnFocus="True"/>
</DataTemplate>
</helper:MyCellTemplateSelector.ColumnUnit>
<helper:MyCellTemplateSelector.ColumnInfo>
<DataTemplate>
<telerik:RadComboBox ItemsSource="{Binding ColumnInfos}" DisplayMemberPath="INF_InfoRad" OpenDropDownOnFocus="True"/>
</DataTemplate>
</helper:MyCellTemplateSelector.ColumnInfo>
<helper:MyCellTemplateSelector.ColumnProperty>
<DataTemplate>
<telerik:RadComboBox ItemsSource="{Binding ColumnProperties}" DisplayMemberPath="KEG_Namn" OpenDropDownOnFocus="True"/>
</DataTemplate>
</helper:MyCellTemplateSelector.ColumnProperty>
</helper:MyCellTemplateSelector>
</telerik:RadGridView.Resources>
</telerik:RadGridView>
