Hi
The following little example should illustrate my problem.
I have three classes in my system:
1. Class Person
- Name
- Age.
2. Class Student : Person (Inherites from Person)
- Grade
3. Class Teacher : Person (Inherites from Person)
- Wage level
My system holds a complete list of Teachers and students like
ObservableCollection<Person>
I have different kinds of GUI controls (listview and radCarousel sofar) that binds to this collection. If I use the radFilterData component in source mode then I see only Name and Age in the field selector. I want to be able to see Name, Age, Grade, Wage level eventhough some of them only makes sence according a specific person type. I use ItemProperties and non source mode to archieve that.
My problem is that I am a little bit confused how to do the rest. I have seen the Domain examples but doesn't guite get it. I assume I have to handle this event:
radDataFilter.FilterDescriptors.CollectionChanged += this.OnRadDataFilterDescriptorsChanged;
But how should I do that. I should also say that I have already implemented sorting and grouping using the
CollectionViewSource.GetDefaultView
Hopefully I will be able to have sorting, grouping and filtering working side by side.
| <telerikNavigation:RadPanelBar x:Name="pb" Margin="5" Width="180" BorderBrush="#9098a3" |
| BorderThickness="1" HorizontalAlignment="Left" ExpandMode="Multiple"> |
| <telerikNavigation:RadPanelBarItem> |
| <telerikNavigation:RadPanelBarItem.Header> |
| <TextBlock Text="מבט ×¢× ×£" Height="13" Margin="5 2 5 2" /> |
| </telerikNavigation:RadPanelBarItem.Header> |
| <telerikNavigation:RadPanelBarItem Header="×ª×•×›× ×™×•×ª עבודה" /> |
| <telerikNavigation:RadPanelBarItem Header="×ž×ž×ª×™× ×•×ª לתקצוב" /> |
| <telerikNavigation:RadPanelBarItem Header="הצעות ×œ×ª×•×›× ×™×ª" /> |
| </telerikNavigation:RadPanelBarItem> |
| <telerikNavigation:RadPanelBarItem> |
| <telerikNavigation:RadPanelBarItem.Header> |
| <TextBlock Text="מבט מחלקה" Height="13" Margin="5 2 5 2" /> |
| </telerikNavigation:RadPanelBarItem.Header> |
| <telerikNavigation:RadPanelBarItem Header="×ª×•×›× ×™×•×ª עבודה" /> |
| <telerikNavigation:RadPanelBarItem Header="×ž×ž×ª×™× ×•×ª לתקצוב" /> |
| <telerikNavigation:RadPanelBarItem Header="הצעות ×œ×ª×•×›× ×™×ª" /> |
| </telerikNavigation:RadPanelBarItem> |
| <telerikNavigation:RadPanelBarItem IsEnabled="True"> |
| <telerikNavigation:RadPanelBarItem.Header> |
| <TextBlock Text="× ×™×”×•×œ המערכת" Height="13" Margin="5 2 5 2" /> |
| </telerikNavigation:RadPanelBarItem.Header> |
| </telerikNavigation:RadPanelBarItem> |
| </telerikNavigation:RadPanelBar> |
#region
Property: Items
private MYOutlookBarItemCollection _items;
public MYOutlookBarItemCollection Items
{
get
{
if (_items == null)
{
_items =
new MYOutlookBarItemCollection ();
}
return _items;
}
}
#endregion
The above code exposes the items property in MYoutlookbar
MYOutlookBarItemCollection.cs will be a separate will which contains
public class MYOutlookBarItemCollection: ObservableCollection<MYOutlookBarItem>
{
}
#region
Property: Content
public object Content
{
get { return (object)GetValue(ContentProperty); }
set { SetValue(ContentProperty, value); }
}
public static readonly DependencyProperty ContentProperty =
DependencyProperty.Register(
"Content", typeof(object), typeof(MyOutlookBarItem),
new FrameworkPropertyMetadata
{
PropertyChangedCallback = (obj, e) =>
{
(obj
as MyOutlookBarItem).UpdateContent((object)e.NewValue);
}
});
private void UpdateContent(object sel)
{
OutlookBarItem.Content = sel;
}
#endregion
Can you guys help me..
Thanks,
Deepz
I am using a heirarchical grid and there are times the childGrid could be null. how to check that condition?
GridViewRow
grdRow = (GridViewRow)grdCell.ParentRow;
RadGridView
childGrid = grdRow.ChildrenOfType<RadGridView>().FirstOrDefault();
Please let me know
Thanks
Sathish.K