This question is locked. New answers and comments are not allowed.
I have a grid and childHierarch, similar to Firstlook example.
I notice that if i filter on some column, and expand and collapse row. Sometimes i hit this exception
Any clue?
I notice that if i filter on some column, and expand and collapse row. Sometimes i hit this exception
Any clue?
Message: Unhandled Error in Silverlight Application
Code: 4008
Category: RuntimeError
Message: Layout cycle detected. Layout could not complete.
MethodName:
Line: 57
Char: 13
Code: 0
4 Answers, 1 is accepted
0
Hi Jingying,
Can you send us an example where we can reproduce this error?
Regards,
Vlad
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Can you send us an example where we can reproduce this error?
Regards,
Vlad
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0

Tim schmidt
Top achievements
Rank 1
answered on 06 Jan 2010, 08:22 PM
Ok, I am getting this error, here is the senerio.
I have a user control:
In colSOComments is just a class with one property;
clsSOCOmment looks like this:
I am filling the data from a WCF Service. the classes and the collection get filled just fine and the data shows just fine when the page comes up. All I am doing is in the App.xaml.vb Application_Startup I have Me.RootVisual = New MyUserControl(), so when I do a F5 in Visual Studio, my usercontrol is the only thing that comes and it has the grid full of data. I get the error when I double click on a cell. I get the error if have have an event handler for the double click (this is code I found on this site)
or if I comment out the AddHandler line in the New() sub. I downloaded the latest trail version of the controls I believe that is Q3 2009 SP1. Any and all help would be greatly appreciated.
I have a user control:
<UserControl xmlns:data="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data" |
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" |
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" |
xmlns:telerikGridView="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.GridView" |
xmlns:TestSite="clr-namespace:TestSiteSL" |
x:Class="TestSiteSL.ucComments" |
Width="500" Height="300" mc:Ignorable="d"> |
<UserControl.Resources> |
<TestSite:colSOComments x:Key="CommentDS"/> |
</UserControl.Resources> |
<Grid x:Name="LayoutRoot" Background="White"> |
<Grid.RowDefinitions> |
<RowDefinition Height="0.124*"/> |
<RowDefinition Height="0.883*"/> |
</Grid.RowDefinitions> |
<CheckBox x:Name="chkShowOnlyActive" Content="Show Only Active Comments" Margin="0,3,0,0"/> |
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Margin="0,0,0,0"> |
<Button x:Name="btnAddComment" HorizontalAlignment="Left" Margin="0,0,15,0" Width="75" Content="Add" d:LayoutOverrides="Height"/> |
<Button x:Name="btnDelComment" HorizontalAlignment="Left" Margin="0,0,15,0" Width="75" Content="Delete" d:LayoutOverrides="Height"/> |
</StackPanel> |
<telerikGridView:RadGridView x:Name="grdComments" Grid.Row="1" ShowGroupPanel="False" CanUserFreezeColumns="False" IsReadOnly="True" |
AutoGenerateColumns="False" ItemsSource="{Binding Source={StaticResource CommentDS}, Path=SOComments}"> |
<telerikGridView:RadGridView.Columns> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding ContactPopUp}" Header="Pop Up"/> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding ActionCode}" Header="Action"/> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding Description}" Header="Description"/> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding CreateBy}" Header="Created By"/> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding CreateDate}" Header="Created Date"/> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding ChangeBy}" Header="Changed By"/> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding ChangeDate}" Header="Changed Date"/> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding RemoveBy}" Header="Removed By"/> |
<telerikGridView:GridViewDataColumn DataMemberBinding="{Binding RemoveDate}" Header="Removed Date"/> |
</telerikGridView:RadGridView.Columns> |
</telerikGridView:RadGridView> |
</Grid> |
</UserControl> |
In colSOComments is just a class with one property;
Imports System.Collections.ObjectModel |
Public Class colSOComments |
Private _colSOComments As ObservableCollection(Of clsSOComment) |
Public Property SOComments() As ObservableCollection(Of clsSOComment) |
Get |
Return _colSOComments |
End Get |
Set(ByVal value As ObservableCollection(Of clsSOComment)) |
_colSOComments = value |
End Set |
End Property |
Public Sub New() |
_colSOComments = New ObservableCollection(Of clsSOComment) |
End Sub |
End Class |
clsSOCOmment looks like this:
Public Class clsSOComment |
Private mintActionCode As Integer |
Private mstrDescription As String |
Private mblnContactPopup As Boolean |
Private mdteCreateDate As Date |
Private mstrCreateBy As String |
Private mdteChangeDate As Date |
Private mstrChangeBy As String |
Private mdteRemoveDate As Nullable(Of Date) |
Private mstrRemoveBy As String |
Private mobjOrigClsSOComment As clsSOComment |
Public Property ActionCode() As Integer |
Get |
Return mintActionCode |
End Get |
Set(ByVal value As Integer) |
mintActionCode = value |
End Set |
End Property |
Public Property Description() As String |
Get |
Return mstrDescription |
End Get |
Set(ByVal value As String) |
mstrDescription = value |
End Set |
End Property |
Public Property ContactPopup() As Boolean |
Get |
Return mblnContactPopup |
End Get |
Set(ByVal value As Boolean) |
mblnContactPopup = value |
End Set |
End Property |
Public Property CreateDate() As Date |
Get |
Return mdteCreateDate |
End Get |
Set(ByVal value As Date) |
mdteCreateDate = value |
End Set |
End Property |
Public Property CreateBy() As String |
Get |
Return mstrCreateBy |
End Get |
Set(ByVal value As String) |
mstrCreateBy = value |
End Set |
End Property |
Public Property ChangeDate() As Date |
Get |
Return mdteChangeDate |
End Get |
Set(ByVal value As Date) |
mdteChangeDate = value |
End Set |
End Property |
Public Property ChangeBy() As String |
Get |
Return mstrChangeBy |
End Get |
Set(ByVal value As String) |
mstrChangeBy = value |
End Set |
End Property |
Public Property RemoveDate() As Nullable(Of Date) |
Get |
Return mdteRemoveDate |
End Get |
Set(ByVal value As Nullable(Of Date)) |
mdteRemoveDate = value |
End Set |
End Property |
Public Property RemoveBy() As String |
Get |
Return mstrRemoveBy |
End Get |
Set(ByVal value As String) |
mstrRemoveBy = value |
End Set |
End Property |
End Class |
I am filling the data from a WCF Service. the classes and the collection get filled just fine and the data shows just fine when the page comes up. All I am doing is in the App.xaml.vb Application_Startup I have Me.RootVisual = New MyUserControl(), so when I do a F5 in Visual Studio, my usercontrol is the only thing that comes and it has the grid full of data. I get the error when I double click on a cell. I get the error if have have an event handler for the double click (this is code I found on this site)
Public Sub New() |
InitializeComponent() |
Me.grdComments.[AddHandler](Controls.GridView.GridViewCell.MouseDoubleClickEvent, New EventHandler(Of RadRoutedEventArgs) _ |
(AddressOf Me.GrdComments_DoubleClick)) |
End Sub |
Private Sub GrdComments_DoubleClick(ByVal sender As Object, ByVal e As RadRoutedEventArgs) |
Dim b As String = "blar" |
End Sub |
0
Hello,
I've tried to reproduce this however everything worked fine - you can check the attached application.
Sincerely yours,
Vlad
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
I've tried to reproduce this however everything worked fine - you can check the attached application.
Sincerely yours,
Vlad
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0

Tim schmidt
Top achievements
Rank 1
answered on 11 Jan 2010, 02:09 PM
thank you for your response. Your example worked fine on my computer. I tried to change my code to mimic what you sent me with no success. I created a new SL app copied my code to a new page and it worked fine. I am not sure what the deal is, but I am assuming there is something wrong with my SL app and I am going to move forward with a new app. Thanks for the help.