Telerik Forums
UI for WPF Forum
4 answers
212 views
I think that RadDocking.GetDockState() of an hidden pane should return
  • either HiddenDockedLeft or DockedLeft for a RadPane hidden left
  • either HiddenDockedTop or DockedTop for a RadPane hidden top
  • either HiddenDockedRight or DockedRight for a RadPane hidden right
  • either HiddenDockedBottom or DockedBottom for a RadPane hidden bottom

Also, it would be great to have PaneStateChanged for after the RadPane had changed.

In my code, I used on LayoutUpdate because I was always one step behind the real tree.
My "workaround" is by getting the property name of the Telerik.Windows.Controls.Docking.AutoHideArea

C# sample:

using System; 
using System.Collections.Generic; 
using System.Linq; 
using System.Text; 
using System.Windows; 
using System.Windows.Controls; 
using System.Windows.Data; 
using System.Windows.Documents; 
using System.Windows.Input; 
using System.Windows.Media; 
using System.Windows.Media.Imaging; 
using System.Windows.Shapes; 
using Telerik.Windows.Controls; 
 
namespace QView 
    /// <summary> 
    /// Interaction logic for Window3.xaml 
    /// </summary> 
    public partial class Window3 : Window 
    { 
        public Window3() 
        { 
            InitializeComponent(); 
        } 
 
        private void RadDocumentPane_MouseDoubleClick(object sender, MouseButtonEventArgs e) 
        { 
            // Create a FlowDocument 
            FlowDocument mcFlowDoc = new FlowDocument(); 
 
            // Create a paragraph with text 
            Paragraph para = new Paragraph(); 
            para.Inlines.Add(new Run("I am a flow document. Would you like to edit me? ")); 
            para.Inlines.Add(new Bold(new Run("Go ahead."))); 
 
            // Add the paragraph to blocks of paragraph 
            mcFlowDoc.Blocks.Add(para); 
 
            // Set contents 
            rtb.Document = mcFlowDoc; 
 
            TextPointer start = rtb.Document.ContentStart; 
            TextPointer startPos = start.GetPositionAtOffset(2); 
            TextPointer endPos = start.GetPositionAtOffset(8); 
            TextRange textRange = new TextRange(startPos, endPos); 
            Console.WriteLine(textRange.Text); 
            textRange.ApplyPropertyValue(TextElement.ForegroundProperty, 
                new SolidColorBrush(Colors.Blue)); 
            textRange.ApplyPropertyValue(TextElement.FontWeightProperty, 
                FontWeights.Bold); 
 
            start = rtb.Document.ContentStart; 
            startPos = start.GetPositionAtOffset(7); 
            endPos = start.GetPositionAtOffset(18); 
            textRange = new TextRange(startPos, endPos); 
            Console.WriteLine(textRange.Text); 
            textRange.ApplyPropertyValue(TextElement.ForegroundProperty, 
                new SolidColorBrush(Colors.Red)); 
            textRange.ApplyPropertyValue(TextElement.FontWeightProperty, 
                FontWeights.Bold); 
             
            startPos = rtb.Document.ContentStart; 
            endPos = rtb.Document.ContentEnd; 
            textRange = new TextRange(startPos, endPos); 
            textRange.ClearAllProperties(); 
        } 
 
        private TreeViewItem FindItem(String p_sFind, ItemCollection p_oIC) 
        { 
            foreach (TreeViewItem oTVI in p_oIC) 
            { 
                if (oTVI.Header.ToString() == p_sFind) 
                { 
                    return oTVI; 
                } 
            } 
            return null
        } 
 
        private void TreeSet(RadSplitContainer p_oRSC, TreeViewItem p_oTVI) 
        { 
            TreeViewItem oTVIGroup; 
            TreeViewItem oTVIChild; 
            object o; 
            for (int nIdx = 0; nIdx < p_oRSC.Items.Count;) 
            { 
                o = p_oRSC.Items[nIdx]; 
                if (o is RadSplitContainer) 
                { 
                    RadSplitContainer oRSC = o as RadSplitContainer; 
                    oTVIGroup = new TreeViewItem(); 
                    oTVIGroup.Header = "RadSplitContainer"
                    TreeSet(o as RadSplitContainer, oTVIGroup); 
                    p_oTVI.Items.Add(oTVIGroup); 
                } 
                else if (o is RadPaneGroup) 
                { 
                    RadPaneGroup oRPG = o as RadPaneGroup; 
                    oTVIGroup = new TreeViewItem(); 
                    oTVIGroup.Header = "Group"
                    if (oRPG.Items.Count != 0) 
                    { 
                        foreach (RadPane oRD in (o as RadPaneGroup).Items) 
                        { 
                            oTVIChild = new TreeViewItem(); 
                            oTVIChild.Header = oRD.Header.ToString(); 
                            oTVIGroup.Items.Add(oTVIChild); 
                        } 
                        p_oTVI.Items.Add(oTVIGroup); 
                    } 
                } 
                else 
                { 
                    Console.WriteLine(o.GetType()); 
                } 
                ++nIdx; 
            } 
        } 
 
        private void radDocking1_LayoutUpdated(object sender, EventArgs e) 
        { 
            radTreeView.Items.Clear(); 
 
            TreeViewItem oTVIChild; 
            TreeViewItem oTVIGroup; 
            TreeViewItem oTVIParent; 
            foreach (RadPane oRP in radDocking1.Panes) 
            { 
                if (oRP.IsFloating || oRP.IsFloatingOnly) 
                { 
                    oTVIParent = FindItem("Floating", radTreeView.Items); 
                    if (oTVIParent == null
                    { 
                        oTVIParent = new TreeViewItem(); 
                        oTVIParent.Header = "Floating"
                        radTreeView.Items.Add(oTVIParent); 
                    } 
                    oTVIChild = new TreeViewItem(); 
                    oTVIChild.Header = oRP.Header; 
                    oTVIParent.Items.Add(oTVIChild); 
                } 
                else if (oRP.IsInDocumentHost) 
                { 
                    oTVIParent = FindItem("Documents", radTreeView.Items); 
                    if (oTVIParent == null
                    { 
                        oTVIParent = new TreeViewItem(); 
                        oTVIParent.Header = "Documents"
                        radTreeView.Items.Add(oTVIParent); 
                    } 
                    oTVIChild = new TreeViewItem(); 
                    oTVIChild.Header = oRP.Header; 
                    oTVIParent.Items.Add(oTVIChild); 
                } 
                else if (!oRP.IsPinned) 
                { 
                    Console.WriteLine(radDocking1); 
                    //Telerik.Windows.Controls.Docking.AutoHideArea.NameProperty 
                    //oTVIParent = FindItem(RadDocking.GetDockState(oRP.Parent).ToString(), radTreeView.Items); 
                    oTVIParent = FindItem(oRP.Parent.GetValue(Telerik.Windows.Controls.Docking.AutoHideArea.NameProperty).ToString(), radTreeView.Items); 
                    Console.WriteLine("RadDocking.GetDockState() with the RadPanel : " + RadDocking.GetDockState(oRP).ToString()); 
                    Console.WriteLine("RadDocking.GetDockState() with the parent(Telerik.Windows.Controls.Docking.AutoHideArea) of the RadPanel : " + RadDocking.GetDockState(oRP.Parent).ToString()); 
                    Console.WriteLine("Name of the Telerik.Windows.Controls.Docking.AutoHideArea : " + oRP.Parent.GetValue(Telerik.Windows.Controls.Docking.AutoHideArea.NameProperty).ToString()); 
                    if (oTVIParent == null
                    { 
                        oTVIParent = new TreeViewItem(); 
                        oTVIParent.Header = oRP.Parent.GetValue(Telerik.Windows.Controls.Docking.AutoHideArea.NameProperty).ToString(); 
                        radTreeView.Items.Add(oTVIParent); 
                    } 
                    oTVIChild = new TreeViewItem(); 
                    oTVIChild.Header = oRP.Header; 
                    oTVIParent.Items.Add(oTVIChild); 
                } 
            } 
 
            foreach (RadSplitContainer oRSC in radDocking1.Items) 
            { 
                oTVIParent = FindItem(RadDocking.GetDockState(oRSC).ToString(), radTreeView.Items); 
                if (oTVIParent == null
                { 
                    oTVIParent = new TreeViewItem(); 
                    oTVIParent.Header = RadDocking.GetDockState(oRSC).ToString(); 
                    radTreeView.Items.Add(oTVIParent); 
                } 
                TreeSet(oRSC, oTVIParent); 
            } 
        } 
 
        private void radDocking1_PreviewShowCompass(object sender, Telerik.Windows.Controls.Docking.PreviewShowCompassEventArgs e) 
        { 
            /*if (e.TargetGroup != null)
            {
                e.Compass.IsCenterIndicatorVisible = CanDockIn(e.DraggedSplitContainer, e.TargetGroup, DockPosition.Center);
                e.Compass.IsLeftIndicatorVisible = CanDockIn(e.DraggedSplitContainer, e.TargetGroup, DockPosition.Left);
                e.Compass.IsTopIndicatorVisible = CanDockIn(e.DraggedSplitContainer, e.TargetGroup, DockPosition.Top);
                e.Compass.IsRightIndicatorVisible = CanDockIn(e.DraggedSplitContainer, e.TargetGroup, DockPosition.Right);
                e.Compass.IsBottomIndicatorVisible = CanDockIn(e.DraggedSplitContainer, e.TargetGroup, DockPosition.Bottom);
            }
            e.Canceled = !(CompassNeedsToShow(e.Compass));*/ 
        } 
 
        private void radDocking1_PaneStateChange(object sender, Telerik.Windows.RadRoutedEventArgs e) 
        { 
             
        } 
    } 
 

XAML:

<Window x:Class="QView.Window3" 
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    xmlns:my="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking"  
    xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" 
    Title="Window3" Height="300" Width="300" > 
    <Grid> 
        <Grid.RowDefinitions> 
            <RowDefinition Height="auto"/> 
            <RowDefinition /> 
        </Grid.RowDefinitions> 
        <telerik:RadMenu x:Name="radMenu" ClickToOpen="False" Grid.Row="0"
            <telerik:RadMenuItem Header="_File"
                <telerik:RadMenuItem Header="New _Tab" > 
                </telerik:RadMenuItem> 
                <telerik:RadMenuItem Header="New _Window"
                </telerik:RadMenuItem> 
                <telerik:RadMenuItem Header="_Open"
                </telerik:RadMenuItem> 
                <telerik:RadMenuItem Header="_Edit with Microsoft Office Word" /> 
            </telerik:RadMenuItem> 
        </telerik:RadMenu> 
        <Grid Grid.Row="1"
            <my:RadDocking x:Name="radDocking1" Height="auto"  PaneStateChange="radDocking1_PaneStateChange" PreviewShowCompass="radDocking1_PreviewShowCompass" LayoutChangeEnded="radDocking1_LayoutUpdated"
                <my:RadDocking.DocumentHost> 
                    <my:RadSplitContainer> 
                        <my:RadPaneGroup> 
                            <my:RadDocumentPane Header="Document 1" Title="Document 1" IsHidden="False" MouseDoubleClick="RadDocumentPane_MouseDoubleClick"
                                <Grid> 
                                    <RichTextBox x:Name="rtb"
                                        <RichTextBox.Document> 
                                            <FlowDocument x:Name="FlowDoc"
                                                <Paragraph x:Name="Paragraph"
                                                    <Bold>New France (French: Nouvelle-France) 
                                                    <Bold>was the</Bold> 
                                                        <Italic>area</Italic> colonized</Bold> by France in North America during a period extending from the exploration of the Saint Lawrence River, by Jacques Cartier in 1534, to the cession of New France to Spain and Britain in 1763. At its peak in 1712 (before the Treaty of Utrecht), the territory of New France extended from Newfoundland to the Rocky Mountains and from Hudson Bay to the Gulf of Mexico. The territory was then divided in five colonies, each with its own administration: Canada, Acadia, Hudson Bay, Newfoundland (Plaisance),[1]  and Louisiana. The Treaty of Utrecht resulted in the relinquishing of French claims to mainland Acadia, the Hudson Bay and Newfoundland colonies, and the establishment of the colony of ÃŽle Royale (Cape Breton Island) as the successor to Acadia.[2][3] 
                                                </Paragraph> 
                                                <Paragraph> 
                                                    Around 1523, the Italian navigator Giovanni da Verrazzano convinced the king, Francis I, to commission an expedition to find a western route to Cathay (China). Late that year, Verrazzano set sail in Dieppe, crossing the Atlantic on a small caravel  with 53 men. After exploring the coast of the present-day Carolinas  early the following year, he headed north along the coast, eventually anchoring in the Narrows of New York Bay. The first European to discover the site of present-day New York, he named it Nouvelle-Angoulême in honour of the king, the former count of Angoulême. Verrazzano’s voyage convinced the king to seek to establish a colony in the newly discovered land. Verrazzano gave the names Francesca and Nova Gallia to that land between New Spain (Mexico) and English Newfoundland.[4] 
                                                </Paragraph> 
                                                <Paragraph> 
                                                    In 1534, Jacques Cartier planted a cross in the Gaspé Peninsula and claimed the land in the name of King Francis I. It was the first province of New France. However, initial French attempts at settling the region met with failure. French fishing fleets, however, continued to sail to the Atlantic coast and into the St. Lawrence River, making alliances with First Nations  that would become important once France began to occupy the land. French merchants soon realized the St. Lawrence region was full of valuable fur-bearing animals, especially the beaver, which was becoming rare in Europe. Eventually, the French crown decided to colonize the territory to secure and expand its influence in America. 
                                                </Paragraph> 
                                                <Paragraph> 
                                                    Another early French attempt at settlement in North America was Fort Caroline, established in what is now Jacksonville, Florida, in 1564. Intended as a haven for Huguenots, Caroline was founded under the leadership of René Goulaine de Laudonnière and Jean Ribault. It was sacked by the Spanish led by Pedro Menéndez de Avilés which then established the settlement of St. Augustine on September 20, 1565. 
                                                </Paragraph> 
                                            </FlowDocument> 
                                        </RichTextBox.Document> 
                                    </RichTextBox> 
                                </Grid> 
                            </my:RadDocumentPane> 
                            <my:RadDocumentPane Header="Document 2" Title="Document 2" IsHidden="False"
                                <Grid /> 
                            </my:RadDocumentPane> 
                            <my:RadDocumentPane Header="Document 3" Title="Document 3" IsHidden="False"
                                <Grid /> 
                            </my:RadDocumentPane> 
                        </my:RadPaneGroup> 
                    </my:RadSplitContainer> 
                </my:RadDocking.DocumentHost> 
                <my:RadSplitContainer Orientation="Vertical" InitialPosition="DockedLeft" Width="150"
                    <my:RadPaneGroup> 
                        <my:RadPane Header="Pane 1" CanDockInDocumentHost="True"
                            <Grid> 
                                <telerik:RadTreeView x:Name="radTreeView"/> 
                            </Grid> 
                        </my:RadPane> 
                        <my:RadPane Header="Pane 2"
                            <Grid> 
                            </Grid> 
                        </my:RadPane> 
                    </my:RadPaneGroup> 
                </my:RadSplitContainer> 
                <my:RadSplitContainer Orientation="Horizontal" InitialPosition="DockedLeft" Width="150"
                    <my:RadPaneGroup> 
                        <my:RadPane Header="Pane 3"
                            <Grid> 
                            </Grid> 
                        </my:RadPane> 
                        <my:RadPane Header="Pane 4"
                            <Grid> 
                            </Grid> 
                        </my:RadPane> 
                    </my:RadPaneGroup> 
                </my:RadSplitContainer> 
            </my:RadDocking> 
        </Grid> 
    </Grid> 
</Window> 
 

Miroslav Nedyalkov
Telerik team
 answered on 19 Mar 2010
3 answers
174 views
I have a RadCalendar set to show 3 rows (months) and SelectionMode is set to Multiple. When you click the days, they highlight, which is great. How do I get the collection of selected dates, and on what event is a day added to the collection? I want to populate a listbox with the selected dates in date order each time a day is selected or unselected.
Hristo
Telerik team
 answered on 19 Mar 2010
1 answer
76 views
Hi,
I would like to dock some of my panes only between themselves and not in other panes.
I would like the compass to show only on top of "legitimate" panes.
How can it be achieved?
Thanks
Nick
Hristo
Telerik team
 answered on 19 Mar 2010
1 answer
58 views
Hello,

I intend to display a duration per XCategory, so I bound the YValue DataPointMember to a TimeSpan. I got an exception then. If I do bind to double value, everything works fine.

What should I do here ? I want to have a good formating on the bar and y-axis here (e.g. 2 Minutes, 1 hour, or 00:11:00).

Thanking you in anticipation
Velin
Telerik team
 answered on 18 Mar 2010
1 answer
86 views
Hello,

I'm using the Carousel-control and need to collapse items in depency of some conditions. So I've tried to bind the Visibility-property of the item to a property of the corresponding object/viewmodel:

<Style TargetType="telerik:CarouselItem">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:CarouselItem">
                        <Grid ToolTip="{Binding Name}" Visibility="{Binding Visibility}">
.......

The result is, that the item is hided but not collapsed, although I set the property to collapsed.

Is there a possibility to collapse items?

Thank you!


Milan
Telerik team
 answered on 18 Mar 2010
8 answers
319 views
Hello

In a situation I set the IsSelected-Property of some RowItems to true. The property "IsSelected" of "GridViewRow" is bound to the grid over DataBinding.

Now I wanted to make sure, that when I select an item from code, which is not visible at this time, it is scrolled into view. So I connected the SelectionChanged-Event of the GridView. The Problem is, the SelectionChanged-Event is only executed, if the item that I'm selecting is already in view! If it's way at the end of the list, the Event is never triggered and so I don't see which item gets selected. As soon as I scroll down and the item jumps into view, the SelectionChanged-Event is triggered.

Any suggestions how I can accomplish this? Things are very losely coupled so I can't just tell the GridView to select the item, it has to operate as soon as one of it's Items has the "IsSelected" property set.

Thanks
NoRyb
NoRyb
Top achievements
Rank 1
 answered on 18 Mar 2010
2 answers
119 views
Hi,

We are using Teleriks Grid as well as WPF Datagrid. I want both grids to have the same styling. We want to go with Teleriks Vista Style. Since the styles are embebbed for telerik, will you be able to provide the styles to me?

Thnx & Rgds

Sujith
Milan
Telerik team
 answered on 18 Mar 2010
2 answers
96 views
Hi.
I just upgraded my project with the lastest DLL's of Q1 2010 version.
I have a view with a RadGridView control displaying a custom object, with the custom columns defined.

The definition of the columns is something like this:

<

 

TelerikControls:RadGridView.Columns>

 

 

 

<TelerikControls:GridViewSelectColumn Header="" />

 

 

 

<TelerikControls:GridViewDataColumn DataMemberBinding="{Binding CodigoAbonado}" Header="{DynamicResource LBL_AccionComercialView_CodigoAbonado}" IsReadOnly="True" IsFilterable="False"/>

 

 

 

<TelerikControls:GridViewDataColumn DataMemberBinding="{Binding CodigoPostal}" Header="{StaticResource LBL_AccionComercialView_CodigoPostal}" IsReadOnly="True" IsFilterable="False"/>

 

 

 

<TelerikControls:GridViewDataColumn Width="Auto" DataMemberBinding="{Binding CuentaNombre}" Header="{DynamicResource LBL_AccionComercialView_NombreCuenta}" IsReadOnly="True" IsFilterable="False"/>

 

 

 

<TelerikControls:GridViewDataColumn DataMemberBinding="{Binding IdFranquicia}" Header="{DynamicResource LBL_AccionComercialView_Franquicia}" IsReadOnly="True" IsFilterable="False"/>

 

 

 

<TelerikControls:GridViewDataColumn DataMemberBinding="{Binding Envios}" Header="{DynamicResource LBL_AccionComercialView_NumeroEnvios}" IsReadOnly="True" IsFilterable="False"/>

 

 

 

<TelerikControls:GridViewDataColumn DataMemberBinding="{Binding Facturacion}" Header="{DynamicResource LBL_AccionComercialView_Facturacion}" IsReadOnly="True" IsFilterable="False"/>

 

 

 

</TelerikControls:RadGridView.Columns>

 

 

 

where "TelerikControls" is
xmlns:TelerikControls="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.GridView"

The application crashed with the following error:

"Null object reference exception.

Original Error StackTrace:

en Telerik.Windows.Controls.DragDrop.RadDragAndDropManager.FindRootVisual()

en Telerik.Windows.Controls.DragDrop.RadDragAndDropManager.Initialize()

en Telerik.Windows.Controls.DragDrop.RadDragAndDropManager.OnAllowDragChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)

en System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e)

en System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e)

en System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args)

en System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, OperationType operationType)

en System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, OperationType operationType, Boolean isInternal)

en System.Windows.DependencyObject.SetValue(DependencyProperty dp, Object value)

en Telerik.Windows.Controls.DragDrop.RadDragAndDropManager.SetAllowDrag(DependencyObject obj, Boolean value)

en Telerik.Windows.Controls.GridView.GridViewHeaderCell.OnApplyTemplate()

en System.Windows.FrameworkElement.ApplyTemplate()

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en Telerik.Windows.Controls.GridView.GridViewCellsPanel.MeasureChild(UIElement child, Size constraint)

en Telerik.Windows.Controls.GridView.GridViewCellsPanel.GenerateChild(IItemContainerGenerator generator, Size constraint, GridViewColumn column, Int32& childIndex, Size& childSize)

en Telerik.Windows.Controls.GridView.GridViewCellsPanel.EnsureAtleastOneHeader(IItemContainerGenerator generator, Size constraint, List`1 realizedColumnIndices, List`1 realizedColumnDisplayIndices)

en Telerik.Windows.Controls.GridView.GridViewCellsPanel.DetermineRealizedColumnsBlockList(Size constraint)

en Telerik.Windows.Controls.GridView.GridViewCellsPanel.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)

en System.Windows.Controls.ItemsPresenter.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Grid.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Control.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Control.MeasureOverride(Size constraint)

en Telerik.Windows.Controls.GridView.GridViewRowItem.MeasureOverride(Size constraint)

en Telerik.Windows.Controls.GridView.GridViewHeaderRow.MeasureOverride(Size availableSize)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.ScrollViewer.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Grid.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Border.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Decorator.MeasureOverride(Size constraint)

en System.Windows.Documents.AdornerDecorator.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Control.MeasureOverride(Size constraint)

en Telerik.Windows.Controls.GridView.GridViewDataControl.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)

en System.Windows.Controls.ScrollContentPresenter.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Border.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.ScrollViewer.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)

en System.Windows.Controls.Grid.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Border.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)

en System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Border.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.Controls.Control.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)

en System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint)

en System.Windows.FrameworkElement.MeasureCore(Size availableSize)

en System.Windows.UIElement.Measure(Size availableSize)

en System.Windows.ContextLayoutManager.UpdateLayout()

en System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)

en System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork()

en System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()

en System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)

en System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)

en System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter)

en System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)

"

Any idea of what's happening?
Is version Q1 2010 not stable for this control?

Thanks in advance.

Alex Martinez
Top achievements
Rank 1
 answered on 18 Mar 2010
1 answer
54 views
Hi,
How can i access InvalidBorder of the row in Q1 2010 release?
In older release i use to do 

void DataGrid_RowLoaded(object sender, RowLoadedEventArgs e)
{
Rectangle rect = e.Row.ChildrenOfType<Rectangle>() 
                .Where(c => c.Name == "InvalidBorder")
                .First() as Rectangle;

But in Q1 2010 release this statement gives exception 
 "Expression cannot contain lambda expressions"
exception message says "Sequence contains no elements"

thx
virendra

Vlad
Telerik team
 answered on 18 Mar 2010
1 answer
15 views
Hello, we want to provide forms, e.g., to administer master data for article (Windows Forms or better WPF).
The users should be able to arrange themselves the fields (text fields, combo, etc.) to form the surface adaptably. Do you have a proposal, how can one realise such a thing?
Hristo
Telerik team
 answered on 18 Mar 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?