This is a migrated thread and some comments may be shown as answers.

[Solved] Resizing Columns in Gridview throws exception.

8 Answers 195 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Claire Kaplan
Top achievements
Rank 1
Claire Kaplan asked on 16 Sep 2010, 11:54 AM
Hi,

I have a Gridview to which I add columns dynamically, when I try to resize the columns I get the following exception:

DataGridLength_Infinity
Parameter name: value
   at Telerik.Windows.Controls.GridViewLength..ctor(Double value, GridViewLengthUnitType type, Double desiredValue, Double displayValue)
   at Telerik.Windows.Controls.GridViewColumn.UpdateWidthForStarColumn(Double displayWidth, Double desiredWidth, Double starValue)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.SetResizedColumnWidth(GridViewColumn column, Double widthDelta, Boolean retainAuto)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.ReallocateStarValuesForNegativeResize(Int32 startIndex, Double horizontalChange, Double perStarLagRatio, Double totalStarFactors, Double perStarWidth, Boolean retainAuto)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.RecomputeStarColumnWidthsOnColumnNegativeResize(Double horizontalChange, Int32 resizingColumnIndex, Double perStarWidth, Boolean retainAuto)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.RecomputeColumnWidthsOnColumnNegativeResize(Double horizontalChange, Int32 resizingColumnIndex, Boolean retainAuto)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.RecomputeColumnWidthsOnColumnResize(GridViewColumn resizingColumn, Double horizontalChange, Boolean retainAuto)
   at Telerik.Windows.Controls.GridView.GridViewHeaderCell.RecomputeColumnWidthsOnColumnResize(GridViewColumn header, Double horizontalChange)
   at Telerik.Windows.Controls.GridView.GridViewHeaderCell.OnColumnHeaderResize(Object sender, DragDeltaEventArgs e)
   at System.Windows.Controls.Primitives.Thumb.OnMouseMove(MouseEventArgs e)
   at System.Windows.Controls.Control.OnMouseMove(Control ctrl, EventArgs e)
   at MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, String eventName)

Is there anything I can do  that needs to be set to get this work?

8 Answers, 1 is accepted

Sort by
0
Tsvyatko
Telerik team
answered on 21 Sep 2010, 03:24 PM
Hello Claire Kaplan,

In order to reproduce the issue you are facing and provide solution we need some additional information.
Could you please specify the version of the controls that you are using, the code used for creating the columns as well as the container where the RadGridView is placed in.

Best wishes,
Tsvyatko
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Manish Kumar
Top achievements
Rank 1
answered on 09 Nov 2010, 12:13 PM
Hi

I am also facing the similar issue. I get an unhandled execption as below while resizing RadGridview column width.
I am using 2010.2.714.1030 SL 3 version gridview. I am displaying Rad chart control in the Gridview row using viewbox.

Unhandled Error in Silverlight Application DataGridLength_Infinity
Parameter name: value   at Telerik.Windows.Controls.GridViewLength..ctor(Double value, GridViewLengthUnitType type, Double desiredValue, Double displayValue)
   at Telerik.Windows.Controls.GridViewColumn.UpdateWidthForStarColumn(Double displayWidth, Double desiredWidth, Double starValue)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.SetResizedColumnWidth(GridViewColumn column, Double widthDelta, Boolean retainAuto)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.ReallocateStarValuesForNegativeResize(Int32 startIndex, Double horizontalChange, Double perStarLagRatio, Double totalStarFactors, Double perStarWidth, Boolean retainAuto)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.RecomputeStarColumnWidthsOnColumnNegativeResize(Double horizontalChange, Int32 resizingColumnIndex, Double perStarWidth, Boolean retainAuto)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.RecomputeColumnWidthsOnColumnNegativeResize(Double horizontalChange, Int32 resizingColumnIndex, Boolean retainAuto)
   at Telerik.Windows.Controls.GridViewColumnCollectionInternal.RecomputeColumnWidthsOnColumnResize(GridViewColumn resizingColumn, Double horizontalChange, Boolean retainAuto)
   at Telerik.Windows.Controls.GridView.GridViewHeaderCell.RecomputeColumnWidthsOnColumnResize(GridViewColumn header, Double horizontalChange)
   at Telerik.Windows.Controls.GridView.GridViewHeaderCell.OnColumnHeaderResize(Object sender, DragDeltaEventArgs e)
   at System.Windows.Controls.Primitives.Thumb.OnMouseMove(MouseEventArgs e)
   at System.Windows.Controls.Control.OnMouseMove(Control ctrl, EventArgs e)
   at MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, Int32 actualArgsTypeIndex, String eventName)

This is container

<

 

Local:GridBase

 

 

xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

 

 

xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

 

 

xmlns:Local="clr-namespace:UIControls"

 

 

xmlns:grid="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.GridView"

 

 

xmlns:telerikGridView="clr-namespace:Telerik.Windows.Controls.GridView;assembly=Telerik.Windows.Controls.GridView"

 

 

xmlns:PAControls="clr-namespace:DerivedControls;assembly=.DerivedControls"

 

 

x:Class="UIControls.GridView" Loaded="TemplateView_Loaded"

 

 

>

 

 

 

<Grid x:Name ="LayoutGrid" >

 

 

 

<Grid.RowDefinitions>

 

 

 

<RowDefinition Height="1.*"/>

 

 

 

</Grid.RowDefinitions>

 

 

 

<Border x:Name="BaseContainer" Grid.Row="0" Margin="5,5,5,0" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" />

 

 

 

</Grid>

 

</

 

Local:GridBase>

 





0
Vlad
Telerik team
answered on 09 Nov 2010, 01:24 PM
Hello,

 Have you tried some our our latest versions? Q2 2010 Sp2, our latest builds or event Q3 2010 Beta?

Regards,
Vlad
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Manish Kumar
Top achievements
Rank 1
answered on 09 Nov 2010, 01:42 PM
Hi

Our bussiness requiment is bounded to use SL 3 version due to some dependency constraints. Also, Even if we use higer version of SL 3 dll's we'll require higher IE plugin version to fit its requirment, which again is not feasible for our project requirement.  So suggest us some way to deal with this issue using the existing version of SL 3 dlls of RadControls.

thanks
Manish
0
Hristo
Telerik team
answered on 11 Nov 2010, 02:31 PM
Hi Manish Kumar,

As of yesterday, with our Q3 2010 release, we discontinued our support for RadControls for Silverlight 3 as announced earlier this year (link). With this said, l would like to remind you that any further developments or fixes will be not possible in RadControls for Silverlight 3. You can use our SL 3 controls in your project but we would be able to assist you in your development only with workarounds (when possible) and not with built-in functionality or bugfixes.

Best wishes,
Hristo
Unit Manager
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Manish Kumar
Top achievements
Rank 1
answered on 24 Nov 2010, 10:48 AM
Hi
I migrated my application to SL4 using VS2010 but the problem is still persisting. I have attached the screenshots of the error while resizing the Gridview column. Is there any way to resolve this issue.

thanks
Manish Kumar
0
Robert Pelzer
Top achievements
Rank 2
answered on 11 Jul 2011, 09:31 PM
I am receiving this error as well and currently on version Silverlight 4 2010 Q1 SP1.  Has this been defintely resolved in the lastest version.  I need some ammo to take to my product owner on reasons for us to upgrade.  If you can assure this is fixed in the latest release then i can ask them for permission to upgrade next quarter.  Also, is there any temporary work around fixes for this.

Thanks,

Ryan
0
Vlad
Telerik team
answered on 12 Jul 2011, 07:10 AM
Hello,

 Indeed this was resolved - you can try our demos

Best wishes,
Vlad
the Telerik team

Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

Tags
GridView
Asked by
Claire Kaplan
Top achievements
Rank 1
Answers by
Tsvyatko
Telerik team
Manish Kumar
Top achievements
Rank 1
Vlad
Telerik team
Hristo
Telerik team
Robert Pelzer
Top achievements
Rank 2
Share this question
or