Hey,
Unfortunately I have a problem in the sort, filter and group functions in the following case:
Class A
{
string AName;
}
Class B : Class A
{
string BName;
}
Class C
{
A baseClass;
}
The item source is ObservableCollection<C>
I am creating in code behind new GridViewDataColum.
If the binding is
1. " baseClass.AName" =>Everything works.
2. " baseClass.BName " =>The grid view rows are ok.All the data is shown in the correct cells,
But the Filter,Group,Sorting is not working.
What can I do?
<telerik:PersistenceManager.SerializationOptions> <telerik:SerializationMetadataCollection> <telerik:PropertyNameMetadata Condition="Only" Expression="IsPinned" SearchType="PropertyName" /> </telerik:SerializationMetadataCollection></telerik:PersistenceManager.SerializationOptions>

Telerik.Windows.Documents.dll!Telerik.Windows.Documents.Model.RadDocument.GetCaretInline() Line 1319 C# Telerik.Windows.Documents.dll!Telerik.Windows.Documents.Model.RadDocument.GetCurrentSpanStyle() Line 1336 + 0xc bytes C# Telerik.Windows.Documents.dll!Telerik.Windows.Controls.RadRichTextBox.UpdateCurrentStyles() Line 2974 + 0x20 bytes C# Telerik.Windows.Documents.dll!Telerik.Windows.Documents.UI.DocumentWebLayoutPresenter.DoOnCaretLocationChanged() Line 441 C# Telerik.Windows.Documents.dll!Telerik.Windows.Documents.UI.DocumentWebLayoutPresenter.DoOnDocumentChanged.AnonymousMethod__6() Line 409 + 0xa bytes C#//Line 1319 in RadDocument.cs SpanLayoutBox previousSpanBox = DocumentStructureCollection.GetPreviousSiblingForDocumentElement(currentSpanBox, currentSpanBox.Parent.AssociatedDocumentElement) as SpanLayoutBox; // ^^^^^NullReferenceException: Parent is null sometimesRadDocument doc = editor.Document; var span1 = new Span("This text is protected");// doc.InsertInline(span1); //this span's spanbox will have no Parent, causing a Null ref (doc.Sections.Last.Blocks.Last as Paragraph).Inlines.Add(span1); //this span's spanbox will have a Parent, not causing a Null ref DocumentPosition pos3 = new DocumentPosition(doc.DocumentLayoutBox, true); var spb1 = span1.FirstLayoutBox as SpanLayoutBox; pos3.MoveToInline(spb1, 0); DocumentPosition pos4 = new DocumentPosition(doc.DocumentLayoutBox, true); pos4.MoveToInline(spb1, spb1.PositionsCountInBox - 1); doc.InsertReadOnlyRange(pos3, pos4); // raises Null ref in RadDocument.GetCaretInline if using "doc.InsertInline"When the view is initially loaded, the RadPanes start out open, and then immediately shut. This is visible and distracting. I really want them to just be closed from the get go.How can I make it so the RadPanes in a RadPaneGroup are initially closed (unpinned)?
How can I make it so the RadPanes in a RadPaneGroup are initially closed (unpinned)?
Code snipet:
| <radDock:RadDocking x:Name="radDocking1" Background="{StaticResource WindowBackgroundBrush}"> |
| <radDock:RadDocking.DocumentHost> |
| <!-- controls here --> |
| </radDock:RadDocking.DocumentHost> |
| <radDock:RadSplitContainer radDock:DockingPanel.InitialSize="300,300" MaxWidth="600" |
| Name="RightContainer" InitialPosition="DockedRight"> |
| <radDock:RadPaneGroup x:Name="_librariesGroup"> |
| <radDock:RadPane x:Name="_requirementsLibraryPane" Header="Requirements Library" |
| CanFloat="False" CanUserClose="False" CanUserPin="True" IsPinned="False"> |
| <my1:RequirementsLibraryDrawerControl x:Name="_requirementsLibraryDrawer" /> |
| </radDock:RadPane> |
| </radDock:RadPaneGroup> |
| </radDock:RadSplitContainer> |
| </radDock:RadDocking> |

I am trying to implement a ContextMenu for a treeview control (WPF) by using your Telerik's online tutorial. However, I often get error message as I copy & paste the tutorial code.
Here is what I have in XAML:
<telerik:RadTreeView Canvas.Left="18" Canvas.Top="136" Height="615" Name="raceTreeView" Width="311" Background="Bisque" IsLineEnabled="True">
<!-- This code segement implements a popup menu on the treeview.-->
<telerik:RadContextMenu.ContextMenu>
<telerik:RadContextMenu ItemClick="TreeContextMenu_ItemClick">
<telerik:RadMenuItem Header="Add" />
<telerik:RadMenuItem Header="Delete" />
<telerik:RadMenuItem Header="Edit" />
</telerik:RadContextMenu>
</telerik:RadContextMenu.ContextMenu>
</telerik:RadTreeView>
Here is the relevant segements in C# code-behind:
using Telerik.Windows;
using Telerik.Windows.Controls;
using Telerik.Windows.Data;
....
private void TreeContextMenu_ItemClick(object sender, Telerik.Windows.RadRoutedEventArgs e)
{
MenuItem item = (e.OriginalSource as RadMenuItem).DataContext as MenuItem;
switch ( item.Text )
{
case "Add":
....
case "Edit":
....
case "Delete":
....
}
}
}
I get an error message on this line : switch ( item.Text )
'System.Windows.Controls.MenuItem' does not contain a definition for 'Text' and no extension method 'Text' accepting a first argument of type 'System.Windows.Controls.MenuItem' could be found (are you missing a using directive or an assembly reference?)
How can I solve this problem?
Thanks,
Hamid
Please disregard this post. I found the error.
Thanks,
Hamid