Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
135
XAMGrid Child Row Selection on Group Row Selection
posted

Hello Team,

I am using XAMDatagrid in WPF. I have used "GroupByPresenter" style to group the records with Checkbox in group row. I am selecting child group records on clicking of checkbox in Header row. 

Now I have two issues. 

1) I have two level grouping - so want check checkbox of second level group when first level(Main Parent) level group checkbox is checked.

2) When user clicks anywhere in area of group row selection of child rows is removed.

I have attached video to give u better understanding of my problem.

It would be great help if u can provide me a solution.

Thanks & Regards,

Vikram U

 

Parents
No Data
Reply
  • 135
    posted

    ----------------------Code------------------------

    <TabControl x:Name="tab_Main" SelectionChanged="tab_Main_SelectionChanged">

    <TabItem Header="Copy Observations" >
    <Border BorderBrush="LightGray" BorderThickness="3" CornerRadius="20" Margin="10">
    <Grid>
    <Grid.ColumnDefinitions>
    <ColumnDefinition MinWidth="250" MaxWidth="300" />
    <ColumnDefinition MinWidth="250" MaxWidth="300" />
    <ColumnDefinition />
    <ColumnDefinition />
    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition Height="50*" />
    <RowDefinition Height="15*" />
    <RowDefinition Height="47*" />
    <RowDefinition Height="409*" />
    <RowDefinition Height="71*" />
    </Grid.RowDefinitions>
    <Border Style="{DynamicResource style_NormalBorder}" x:Name="HeaderLabelBorder" Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="4" >
    <Border.Background>
    <ImageBrush ImageSource="/MMC_SmartCopy;component/Images/Blue_HeaderBackground.png" />
    </Border.Background>
    <Label Content="Smart Copy Tool" Name="lbl_Header" Grid.ColumnSpan="4" Style="{DynamicResource MainHeaderLabel}" Grid.Row="0" Grid.Column="0">
    <!--<Label.Background>
    <ImageBrush ImageSource="/CopyForwardUtility;component/Images/Blue_HeaderBackground.png" />
    </Label.Background>-->
    </Label>
    </Border>
    <Border Style="{DynamicResource style_NormalBorder}" x:Name="DocumentTreeBorder" Grid.Column="0" Grid.Row="2" Grid.RowSpan="2">
    <Border.Background>
    <ImageBrush ImageSource="/MMC_SmartCopy;component/Images/Blue_SquareBoxWithBorder.png" />
    </Border.Background>
    <StackPanel Style="{DynamicResource style_StackPanel}">
    <Label Name="lbl_SelectDoc" Content="Select Document" Style="{DynamicResource HeaderLabel}" Grid.Row="2" Grid.Column="0"/>
    <!--<TreeView Name="tvDocument" ItemsSource="{Binding}" SelectedItemChanged="tvDocument_SelectedItemChanged"
    Loaded="tvDocument_Loaded" Style="{StaticResource style_Treeview}" Grid.Row="3" Grid.Column="0" BorderThickness="0" >

    <TreeView.Resources>
    <Style TargetType="{x:Type TreeViewItem}">
    <Setter Property="HeaderTemplate">
    <Setter.Value>
    <DataTemplate>
    <StackPanel Orientation="Horizontal">
    <CheckBox Name="chkDocument" Margin="2" Tag="{Binding DocumentGUID}" Checked="chkDocument_Checked" Unchecked="chkDocument_Unchecked" >
    </CheckBox>

    <TextBlock Text="{Binding DocumentName}"></TextBlock>
    </StackPanel>
    </DataTemplate>
    </Setter.Value>
    </Setter>
    </Style>
    </TreeView.Resources>

    </TreeView>-->

    <ListView x:Name="lvDocument" SelectionMode="Single" ItemsSource="{Binding}" Style="{DynamicResource style_Listview}" SelectionChanged="lvDocument_SelectionChanged" Grid.Row="3" Grid.Column="0" BorderThickness="0" >
    <ListView.View>
    <GridView>
    <GridView.Columns >
    <GridViewColumn >
    <GridViewColumn.CellTemplate>
    <DataTemplate>
    <StackPanel Orientation="Horizontal">
    <CheckBox IsChecked="{Binding IsSelected,RelativeSource={RelativeSource FindAncestor,AncestorType={x:Type ListViewItem}}}" />
    <TextBlock Text="{Binding DocumentName}" />
    </StackPanel>
    </DataTemplate>
    </GridViewColumn.CellTemplate>
    </GridViewColumn>
    <GridViewColumn DisplayMemberBinding="{Binding DocumentGUID}" Header="Document GUID" Width="0"/>
    <GridViewColumn DisplayMemberBinding="{Binding PatCareDocGUID}" Header="PatcareGUID" Width="0"/>

    </GridView.Columns>
    </GridView>
    </ListView.View>
    </ListView>
    </StackPanel>
    </Border>
    <!--<Border Style="{StaticResource style_NormalBorder}" x:Name="ObservationTreeBorder" Grid.Column="1" Grid.Row="2" Grid.RowSpan="2" Grid.ColumnSpan="3" >
    <ScrollViewer HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto">
    <StackPanel Style="{StaticResource style_StackPanel}" >

    <Label Content="Select Observations" Name="lbl_SelectObservation" Grid.Column="1" Grid.Row="2" Style="{StaticResource HeaderLabel}" />

    <igDP:XamDataGrid Name="dgObservation" DataSource="{Binding}" SortRecordsByDataType="False" CellChanged="dgObservation_CellChanged" InitializeRecord="dgObservation_InitializeRecord" >
    -->
    <!--<igDP:XamDataGrid.FieldSettings>
    <igDP:FieldSettings AllowEdit="False"/>
    </igDP:XamDataGrid.FieldSettings>-->
    <!--

    </igDP:XamDataGrid>

    </StackPanel>
    </ScrollViewer>
    </Border>-->

    <Border Style="{DynamicResource style_NormalBorder}" x:Name="ObservationTreeBorder" Grid.Column="1" Grid.Row="2" Grid.RowSpan="2" Grid.ColumnSpan="3" >
    <ScrollViewer HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto">
    <StackPanel Style="{DynamicResource style_StackPanel}" >

    <Label Content="Select Observations" Name="lbl_SelectObservation" Grid.Column="1" Grid.Row="2" Style="{DynamicResource HeaderLabel}" />
    <!--MouseLeftButtonUp="GroupBySummariesPresenter_MouseRightButtonUp"-->
    <igDP:XamDataGrid Name="dgObservation"
    DataSource="{Binding}"
    SortRecordsByDataType="False"
    Margin="5,5,5,5"
    InitializeRecord="dgObservation_InitializeRecord"
    >


    <igDP:XamDataGrid.Resources>
    <!-- This Style puts a CheckBox into the record selectors. -->
    <Style TargetType="{x:Type igDP:RecordSelector}" x:Key="RecordSelectorStyle1">
    <Setter Property="Template">
    <Setter.Value>
    <ControlTemplate TargetType="{x:Type igDP:RecordSelector}">
    <CheckBox HorizontalAlignment="Center"
    VerticalAlignment="Center"
    x:Name="chkRecordSelector"
    IsChecked="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Record.IsSelected, Mode=TwoWay}"/>
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    </Style>
    <Style TargetType="{x:Type igDP:HeaderPrefixArea}" BasedOn="{x:Null}" x:Key="HeaderPrefixAreaStyle1">
    <Setter Property="Visibility" Value="Visible" />
    <Setter Property="Template">
    <Setter.Value>
    <ControlTemplate TargetType="{x:Type igDP:HeaderPrefixArea}">
    <CheckBox HorizontalAlignment="Center"
    VerticalAlignment="Center"

    />
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    </Style>
    <Style TargetType="{x:Type igDP:HeaderPrefixArea}" BasedOn="{x:Null}" x:Key="headerPrefixAreaStyle2">
    <Setter Property="Visibility" Value="Visible" />
    <Setter Property="Template">
    <Setter.Value>
    <ControlTemplate TargetType="{x:Type igDP:HeaderPrefixArea}">
    <CheckBox HorizontalAlignment="Center"
    VerticalAlignment="Center"
    IsChecked="{Binding Path=DataPresenter.DataContext.AllMembersFriendsAreChecked, Mode=TwoWay}"
    />
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    </Style>

    <Style x:Key="GroupByRecordPresenterStyle" TargetType="{x:Type igDP:GroupByRecordPresenter}">

    <Setter Property="Background" Value="#00FFFFFF"/>

    <Setter Property="Height" Value="15"/>
    <Setter Property="FontSize" Value="12"></Setter>
    <Setter Property="FontWeight" Value="Bold"></Setter>
    <Setter Property="Foreground" Value="#005290"></Setter>
    <Setter Property="BorderBrush" Value="Transparent"></Setter>
    <Setter Property="BorderThickness" Value="0"></Setter>


    <Setter Property="Template">
    <Setter.Value>
    <ControlTemplate TargetType="{x:Type igDP:GroupByRecordPresenter}">
    <ControlTemplate.Resources>
    <Storyboard x:Key="sbDisplayNested">
    <DoubleAnimationUsingKeyFrames
    BeginTime="00:00:00"
    Storyboard.TargetName="ncpVisual"
    Storyboard.TargetProperty="Opacity"
    FillBehavior="HoldEnd">
    <DiscreteDoubleKeyFrame Value="0" KeyTime="00:00:00"/>
    <DiscreteDoubleKeyFrame Value="0" KeyTime="00:00:00.25"/>
    <SplineDoubleKeyFrame KeySpline="0.5,0.5,0.5,0.5" Value="1" KeyTime="00:00:0.75"/>
    </DoubleAnimationUsingKeyFrames>
    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ncpVisual" Storyboard.TargetProperty="(UIElement.Visibility)">
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Visible}" KeyTime="00:00:00"/>
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Collapsed}" KeyTime="00:00:0.75"/>
    </ObjectAnimationUsingKeyFrames>
    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ncpMask" Storyboard.TargetProperty="(UIElement.Visibility)">
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Visible}" KeyTime="00:00:00"/>
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Collapsed}" KeyTime="00:00:0.75"/>
    </ObjectAnimationUsingKeyFrames>
    </Storyboard>
    <Storyboard x:Key="sbHideNested">
    <DoubleAnimationUsingKeyFrames
    BeginTime="00:00:00"
    Storyboard.TargetName="NestedContentPresenter"
    Storyboard.TargetProperty="Opacity"
    FillBehavior="HoldEnd">
    <SplineDoubleKeyFrame KeySpline="0.5,0.5,0.5,0.5" Value="1" KeyTime="00:00:00.15"/>
    </DoubleAnimationUsingKeyFrames>
    </Storyboard>
    </ControlTemplate.Resources>
    <Grid Background="{TemplateBinding Background}">
    <Grid.ColumnDefinitions>
    <ColumnDefinition Width="Auto"/>
    <ColumnDefinition Width="*"/>
    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition x:Name="row0" Height="Auto"/>
    <RowDefinition x:Name="row1" Height="Auto"/>
    <RowDefinition x:Name="row2" Height="*"/>
    </Grid.RowDefinitions>
    <!-- Row for nested content -->
    <!-- Expansion Checkbox -->
    <!-- AS 1/27/09 NA 2009 Vol 1 - Set ZIndex and RenderTransform for fixed fields -->
    <!-- AS 6/3/09 NA 2009 Vol 2 - Added Command(Parameter) & ToggleMode to support undo/redo -->
    <igDPWindows:ExpansionIndicator x:Name="ExpansionIndicator"
    RenderTransform="{TemplateBinding FixedNearElementTransform}"
    Panel.ZIndex="1"
    Grid.Row="1"
    Visibility="{TemplateBinding ExpansionIndicatorVisibility}"
    Command="{x:Static igDP:DataPresenterCommands.ToggleRecordIsExpanded}"
    CommandParameter="{TemplateBinding Record}"
    ToggleMode="Manual"
    />
    <!--IsChecked="{Binding Path=IsExpanded, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"-->
    <!-- JJD 10/10/12 - TFS123036
    Added HeaderContentBackground so that the header area would span the entire width of the GroupByPresenter -->
    <Rectangle
    x:Name="HeaderContentBackground"
    Fill="{DynamicResource {ComponentResourceKey TypeInTargetAssembly={x:Type igDP:XamDataGrid}, ResourceId=LabelBackground}}"
    Grid.Row="0"
    Grid.Column="0"
    Grid.ColumnSpan="2"
    HorizontalAlignment="Stretch"
    VerticalAlignment="Stretch"
    />
    <!-- JJD 6/4/09 - TFS17060 - Added Header site to support HeaderPlacementInGroupBy 'OnTop' in reporting -->
    <ContentPresenter
    x:Name="PART_HeaderContentSite"
    Grid.Row="0"
    Grid.Column="1"
    Content="{TemplateBinding HeaderContent}"
    Visibility="{Binding Path=HasHeaderContent, RelativeSource={RelativeSource TemplatedParent}}"
    HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
    VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
    />

    <!-- Record content site -->
    <!-- AS 1/27/09 NA 2009 Vol 1 - Set RenderTransform for fixed fields -->
    <Grid
    x:Name="PART_RecordContentSite"
    RenderTransform="{TemplateBinding FixedNearElementTransform}"
    Margin="0"
    Grid.Row="1"
    Grid.Column="1"
    Visibility="Collapsed">

    <StackPanel Orientation="Horizontal" Name="MySTACK" Background="Red" MouseLeftButtonDown="MySTACK_MouseLeftButtonDown">
    <CheckBox VerticalAlignment="Center" HorizontalAlignment="Stretch" HorizontalContentAlignment="Stretch"
    Click="CheckBox_Click" Name="myChk"
    Loaded="CheckBox_Loaded"
    Content="{Binding Path=Description,RelativeSource={RelativeSource TemplatedParent}}"
    />
    <!--<TextBlock VerticalAlignment="{TemplateBinding VerticalContentAlignment}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Text="{Binding Path=Description, RelativeSource={RelativeSource TemplatedParent}}" ></TextBlock>-->
    <!--<ContentControl

    Content="{Binding Path=Description, RelativeSource={RelativeSource TemplatedParent}}"
    VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
    HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"

    />-->
    <!-- SSP 4/3/08 - Summaries Functionality -->
    <!-- AS 1/27/09 NA 2009 Vol 1 - Set RenderTransform for fixed fields -->
    <igDP:GroupBySummariesPresenter
    RenderTransform="{TemplateBinding ScrollableElementTransform}"
    HorizontalAlignment="Left"
    x:Name="GroupBySummariesPresenter"
    Visibility="Collapsed"
    GroupByRecord="{TemplateBinding Record }"
    />
    </StackPanel>
    </Grid>
    <!-- Nested Content -->
    <Grid
    x:Name="PART_NestedContentSite"
    Grid.Row="2"
    Grid.Column="1"
    Visibility="Collapsed">
    <!-- AS 2/13/09 TFS13978 - Set RenderTransform for fixed fields -->
    <Border
    CornerRadius="0,0,3,3"
    BorderBrush="#44102975"
    BorderThickness="1"
    RenderTransform="{TemplateBinding FixedNearElementTransform}"
    >
    <Border.Background>
    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
    <GradientStop Color="#FFFFFFFF" Offset="0.25"/>
    <GradientStop Color="#FFEEEEEE" Offset="1.2"/>
    </LinearGradientBrush>
    </Border.Background>
    <!-- AS 3/25/09 TFS15801 -->
    <ContentControl
    RenderTransform="{TemplateBinding ScrollableElementTransform}"
    x:Name="NestedContentPresenter"
    Content="{Binding Path=NestedContent, RelativeSource={RelativeSource TemplatedParent}}"
    />
    <!--Margin="0,0,0,5"-->
    </Border>
    <!-- AS 11/14/07 BR26035
    The namescope was broken because the recordlistcontrol was not in the logical tree. We
    need to use a ContentControl instead so the content is made a logical child. -->
    <!-- AS 3/25/09 TFS15801
    This should be nested within the Border above.
    <ContentControl x:Name="NestedContentPresenter" Content="{Binding Path=NestedContent, RelativeSource={RelativeSource TemplatedParent}}" Margin="0,0,0,5"/>-->
    </Grid>
    </Grid>
    <ControlTemplate.Triggers>
    <!-- AS 11/8/11 TFS88111 -->
    <MultiDataTrigger>
    <MultiDataTrigger.Conditions>
    <Condition Binding="{Binding Path=FieldLayout.AutoFitToWidth, RelativeSource={RelativeSource Self}}" Value="True" />
    <Condition Binding="{Binding Path=Orientation, RelativeSource={RelativeSource Self}}" Value="Vertical" />
    </MultiDataTrigger.Conditions>
    <Setter TargetName="PART_HeaderContentSite" Property="Grid.ColumnSpan" Value="2"/>
    <Setter TargetName="PART_RecordContentSite" Property="Grid.ColumnSpan" Value="2"/>
    <Setter TargetName="GroupBySummariesPresenter" Property="HorizontalAlignment" Value="Stretch"/>
    <!-- AS 4/26/13 TFS138379 -->
    <Setter TargetName="PART_HeaderContentSite" Property="HorizontalAlignment" Value="Stretch"/>
    </MultiDataTrigger>

    <Trigger Property="ShouldDisplayGroupByRecordContent" Value="true">
    <Setter TargetName="PART_RecordContentSite" Property="Visibility" Value="Visible"/>
    </Trigger>
    <Trigger Property="ShouldDisplayGroupByRecordContent" Value="false">
    <Setter TargetName="ExpansionIndicator" Property="Visibility" Value="Hidden"/>
    </Trigger>
    <!-- SSP 4/3/08 - Summaries Functionality -->
    <Trigger Property="ShouldDisplaySummaryCells" Value="true">
    <Setter TargetName="GroupBySummariesPresenter" Property="Visibility" Value="Visible"/>
    </Trigger>
    <MultiTrigger>
    <MultiTrigger.Conditions>
    <Condition Property="Orientation" Value="Vertical"/>
    <Condition Property="ShouldDisplayGroupByRecordContent" Value="false"/>
    </MultiTrigger.Conditions>
    <Setter TargetName="ExpansionIndicator" Property="Grid.Row" Value="2"/>
    </MultiTrigger>

    <!-- JJD 1/20/09 - In horizontal mode we need to leave the height on the content area visible -->
    <MultiTrigger>
    <MultiTrigger.Conditions>
    <Condition Property="Orientation" Value="Horizontal"/>
    <Condition Property="ShouldDisplayGroupByRecordContent" Value="false"/>
    </MultiTrigger.Conditions>
    <Setter TargetName="PART_RecordContentSite" Property="Visibility" Value="Visible"/>
    </MultiTrigger>

    <Trigger Property="HasNestedContent" Value="true">
    <Setter TargetName="PART_NestedContentSite" Property="Visibility" Value="Visible"/>
    </Trigger>

    <!-- MD 6/10/10 - ChildRecordsDisplayOrder feature-->
    <MultiDataTrigger>
    <MultiDataTrigger.Conditions>
    <Condition Binding="{Binding Path=FieldLayout.ChildRecordsDisplayOrderResolved}" Value="BeforeParent"/>
    <Condition Binding="{Binding Path=Orientation, RelativeSource={RelativeSource Self}}" Value="Vertical"/>
    </MultiDataTrigger.Conditions>
    <Setter TargetName="PART_NestedContentSite" Property="Grid.Row" Value="0" />
    <Setter TargetName="PART_HeaderContentSite" Property="Grid.Row" Value="1" />
    <!-- JJD 10/10/12 - TFS123036
    Added HeaderContentBackground so that the header area would span the entire width of the GroupByPresenter -->
    <Setter TargetName="HeaderContentBackground" Property="Grid.Row" Value="1" />
    <Setter TargetName="ExpansionIndicator" Property="Grid.Row" Value="2" />
    <Setter TargetName="PART_RecordContentSite" Property="Grid.Row" Value="2" />
    <Setter TargetName="row0" Property="Height" Value="*" />
    <Setter TargetName="row2" Property="Height" Value="Auto" />
    </MultiDataTrigger>

    <!-- MD 8/3/10 - TFS35609 -->
    <MultiDataTrigger>
    <MultiDataTrigger.Conditions>
    <Condition Binding="{Binding Path=FieldLayout.ChildRecordsDisplayOrderResolved}" Value="BeforeParentHeadersAttached"/>
    <Condition Binding="{Binding Path=Orientation, RelativeSource={RelativeSource Self}}" Value="Vertical"/>
    </MultiDataTrigger.Conditions>
    <Setter TargetName="PART_NestedContentSite" Property="Grid.Row" Value="0" />
    <Setter TargetName="PART_HeaderContentSite" Property="Grid.Row" Value="1" />
    <!-- JJD 10/10/12 - TFS123036
    Added HeaderContentBackground so that the header area would span the entire width of the GroupByPresenter -->
    <Setter TargetName="HeaderContentBackground" Property="Grid.Row" Value="1" />
    <Setter TargetName="ExpansionIndicator" Property="Grid.Row" Value="2" />
    <Setter TargetName="PART_RecordContentSite" Property="Grid.Row" Value="2" />
    <Setter TargetName="row0" Property="Height" Value="*" />
    <Setter TargetName="row2" Property="Height" Value="Auto" />
    </MultiDataTrigger>

    </ControlTemplate.Triggers>
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    <Setter Property="TemplateCardView">
    <Setter.Value>
    <ControlTemplate TargetType="{x:Type igDP:GroupByRecordPresenter}">
    <ControlTemplate.Resources>
    <Storyboard x:Key="sbDisplayNested">
    <DoubleAnimationUsingKeyFrames
    BeginTime="00:00:00"
    Storyboard.TargetName="ncpVisual"
    Storyboard.TargetProperty="Opacity"
    FillBehavior="HoldEnd">
    <DiscreteDoubleKeyFrame Value="0" KeyTime="00:00:00"/>
    <DiscreteDoubleKeyFrame Value="0" KeyTime="00:00:00.25"/>
    <SplineDoubleKeyFrame KeySpline="0.5,0.5,0.5,0.5" Value="1" KeyTime="00:00:0.75"/>
    </DoubleAnimationUsingKeyFrames>
    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ncpVisual" Storyboard.TargetProperty="(UIElement.Visibility)">
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Visible}" KeyTime="00:00:00"/>
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Collapsed}" KeyTime="00:00:0.75"/>
    </ObjectAnimationUsingKeyFrames>
    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ncpMask" Storyboard.TargetProperty="(UIElement.Visibility)">
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Visible}" KeyTime="00:00:00"/>
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Collapsed}" KeyTime="00:00:0.75"/>
    </ObjectAnimationUsingKeyFrames>
    </Storyboard>
    <Storyboard x:Key="sbHideNested">
    <DoubleAnimationUsingKeyFrames
    BeginTime="00:00:00"
    Storyboard.TargetName="NestedContentPresenter"
    Storyboard.TargetProperty="Opacity"
    FillBehavior="HoldEnd">
    <SplineDoubleKeyFrame KeySpline="0.5,0.5,0.5,0.5" Value="1" KeyTime="00:00:00.15"/>
    </DoubleAnimationUsingKeyFrames>
    </Storyboard>
    </ControlTemplate.Resources>
    <Grid Background="{TemplateBinding Background}">
    <Grid.ColumnDefinitions>
    <ColumnDefinition Width="*" MinWidth="20"/>
    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition Height="Auto"/>
    <RowDefinition Height="*"/>
    </Grid.RowDefinitions>
    <!-- Row for nested content -->
    <!-- Record content site -->
    <Grid
    x:Name="PART_RecordContentSite"
    Margin="0"
    Grid.Row="1"
    Grid.Column="0"
    Visibility="Collapsed"
    >
    <!-- Background Bar -->
    <Border
    HorizontalAlignment="Stretch"
    VerticalAlignment="Stretch"
    Width="Auto"
    Height="Auto"
    RenderTransformOrigin="0.5,0.5"
    CornerRadius="2,2,2,2"
    SnapsToDevicePixels="True"
    Background="{DynamicResource {ComponentResourceKey TypeInTargetAssembly={x:Type igDP:XamDataGrid}, ResourceId=LabelBackground}}">
    <Grid Margin="0,0,0,0" Width="Auto" Height="Auto">
    <Rectangle
    Stroke="#44000000"
    StrokeThickness="1"
    RadiusX="1.55015910897703"
    RadiusY="1.55015910897703"
    Fill="Transparent"/>
    <!--Margin="1"-->
    <Rectangle

    Stroke="#44FFFFFF"
    StrokeThickness="1"
    RadiusX="0.550159108977027"
    RadiusY="0.550159108977027"
    Fill="Transparent"/>
    </Grid>
    </Border>
    <!-- End Background Bar -->
    <Border
    x:Name="highlight"
    HorizontalAlignment="Stretch"
    VerticalAlignment="Stretch"
    Width="Auto"
    Height="Auto"
    CornerRadius="2,2,2,2"
    Background="{DynamicResource {ComponentResourceKey TypeInTargetAssembly={x:Type igDP:XamDataGrid}, ResourceId=LabelHighlight}}">
    <Grid Margin="0,0,0,0" Width="Auto" Height="Auto">
    <Rectangle
    Stroke="#44000000"
    StrokeThickness="1"
    RadiusX="1.55015910897703"
    RadiusY="1.55015910897703"
    Fill="Transparent"/>
    <!--Margin="1"-->
    <Rectangle

    Stroke="#44FFFFFF"
    StrokeThickness="1"
    RadiusX="0.550159108977027"
    RadiusY="0.550159108977027"
    Fill="Transparent"/>
    </Grid>
    </Border>
    <!-- End Add 8/1/2006 GH-->
    <!-- Label Text -->
    <StackPanel Orientation="Vertical">
    <ContentControl
    Style="{StaticResource ControlHeaderLabel}"
    Content="{Binding Path=Description, RelativeSource={RelativeSource TemplatedParent}}"
    VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
    HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"/>
    <!-- SSP 4/3/08 - Summaries Functionality -->
    <igDP:GroupBySummariesPresenter
    Grid.Row="1"
    HorizontalAlignment="Left"
    x:Name="GroupBySummariesPresenter"
    Visibility="Collapsed"
    GroupByRecord="{TemplateBinding Record}"/>
    </StackPanel>
    </Grid>
    <!-- Nested Content -->
    <Grid
    x:Name="PART_NestedContentSite"
    Grid.Row="1"
    Grid.Column="0"
    Visibility="Collapsed">
    <!--<igWindows:NestedContentBackground/>-->
    <Border CornerRadius="0,0,3,3" BorderBrush="#44102975" BorderThickness="1">
    <Border.Background>
    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
    <GradientStop Color="#FFFFFFFF" Offset="0.25"/>
    <GradientStop Color="#FFEEEEEE" Offset="1.2"/>
    </LinearGradientBrush>
    </Border.Background>
    <!-- AS 3/25/09 TFS15801 -->
    <ContentControl x:Name="NestedContentPresenter" Content="{Binding Path=NestedContent, RelativeSource={RelativeSource TemplatedParent}}"
    />
    <!--Margin="0,0,0,5"-->
    </Border>
    <!-- AS 11/14/07 BR26035
    The namescope was broken because the recordlistcontrol was not in the logical tree. We
    need to use a ContentControl instead so the content is made a logical child. -->
    <!-- AS 3/25/09 TFS15801
    This should be nested within the Border above.
    <ContentControl x:Name="NestedContentPresenter" Content="{Binding Path=NestedContent, RelativeSource={RelativeSource TemplatedParent}}" Margin="0,0,0,5"/>-->
    </Grid>
    </Grid>
    <ControlTemplate.Triggers>
    <Trigger Property="ShouldDisplayGroupByRecordContent" Value="true">
    <Setter TargetName="PART_RecordContentSite" Property="Visibility" Value="Visible"/>
    </Trigger>
    <!--<Trigger Property="ShouldDisplayGroupByRecordContent" Value="false"/>-->
    <!-- SSP 4/3/08 - Summaries Functionality -->
    <Trigger Property="ShouldDisplaySummaryCells" Value="true">
    <Setter TargetName="GroupBySummariesPresenter" Property="Visibility" Value="Visible"/>
    </Trigger>
    <Trigger Property="HasNestedContent" Value="true">
    <Setter TargetName="PART_NestedContentSite" Property="Visibility" Value="Visible"/>
    </Trigger>
    </ControlTemplate.Triggers>
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    </Style>
    </igDP:XamDataGrid.Resources>
    <!--HeaderPrefixAreaStyle="{StaticResource HeaderPrefixAreaStyle1}-->
    <igDP:XamDataGrid.FieldLayoutSettings>
    <igDP:FieldLayoutSettings AutoGenerateFields="False" RecordSelectorStyle="{StaticResource RecordSelectorStyle1}" />
    </igDP:XamDataGrid.FieldLayoutSettings>

    <igDP:XamDataGrid.FieldLayouts >
    <igDP:FieldLayout>
    <igDP:FieldLayout.Settings >
    <igDP:FieldLayoutSettings ></igDP:FieldLayoutSettings>
    </igDP:FieldLayout.Settings>
    <igDP:FieldLayout.Fields >

    <igDP:Field Name="Observation" Label="Observation" Width="200*" >
    <igDP:Field.Settings>
    <igDP:FieldSettings AllowEdit="False" />

    </igDP:Field.Settings>

    </igDP:Field>
    <igDP:Field Name="Value" Label="Charted value" Width="500*" >
    <igDP:Field.Settings>
    <igDP:FieldSettings AllowEdit="False" />

    </igDP:Field.Settings>

    </igDP:Field>
    <igDP:Field Name="ParameterGUID" Label="ParameterGUID" Visibility="Hidden"></igDP:Field>
    <igDP:Field Name="SectionHeader" Label="Section" Visibility="Hidden"></igDP:Field>
    <igDP:Field Name="SetHeader" Label="Set" Visibility="Hidden"/>

    </igDP:FieldLayout.Fields>
    <igDP:FieldLayout.SortedFields >
    <igDP:FieldSortDescription FieldName="SectionHeader" IsGroupBy="True"></igDP:FieldSortDescription>
    <igDP:FieldSortDescription FieldName="SetHeader" IsGroupBy="True"></igDP:FieldSortDescription>
    </igDP:FieldLayout.SortedFields>

    </igDP:FieldLayout>

    </igDP:XamDataGrid.FieldLayouts>

    <igDP:XamDataGrid.FieldSettings >
    <igDP:FieldSettings GroupByRecordPresenterStyle="{StaticResource GroupByRecordPresenterStyle}"/>

    </igDP:XamDataGrid.FieldSettings >

    </igDP:XamDataGrid>

    </StackPanel>
    </ScrollViewer>
    </Border>

    <Grid Grid.Column="0" Grid.Row="4" Grid.ColumnSpan="4">
    <Grid.ColumnDefinitions >
    <ColumnDefinition Width="250"/>
    <ColumnDefinition />

    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition Height="50*" />

    </Grid.RowDefinitions>

    <!--<StackPanel Style="{StaticResource style_ButtonStackPanel}" Grid.Column="1" Grid.Row="4">-->
    <!--<Border Style="{StaticResource style_ButtonBorder}" x:Name="Border_Button1" Grid.Column="0" Grid.Row="0" HorizontalAlignment="Left">-->

    <Button x:Name="btnCopy" Content="Copy Selection" Click="btnCopy_Click" Grid.Row="0" Grid.Column="0" Style="{DynamicResource style_Button}"/>
    <Button x:Name="btnCancelCopy" Content="Cancel Copy" Click="btnCancelCopy_Click" Grid.Row="0" Grid.Column="1" Style="{DynamicResource style_Button}" HorizontalAlignment="Left"/>
    <!--</Border>-->
    <!--</StackPanel>-->
    <!--<Border Style="{StaticResource style_ButtonBorder}" x:Name="Border_Button2" Grid.Column="1" Grid.Row="0" Width="100" HorizontalAlignment="Left">
    <Button x:Name="btnCancelCopy" Content="Cancel Copy" Click="btnCancelCopy_Click" Grid.Row="0" Grid.Column="1" Style="{StaticResource style_Button}"/>
    </Border>-->
    </Grid>
    </Grid>
    </Border>

    </TabItem>
    <TabItem Header="Confirm Copy">
    <Border BorderBrush="LightGray" BorderThickness="3" CornerRadius="20" Margin="10">
    <Grid>
    <Grid.ColumnDefinitions>
    <ColumnDefinition Width="500*"/>

    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition Height="50*" />

    <RowDefinition Height="400*" />

    </Grid.RowDefinitions>

    <Grid Grid.Column="0" Grid.Row="0" Grid.ColumnSpan="1">
    <Grid.ColumnDefinitions >
    <ColumnDefinition Width="250"/>
    <ColumnDefinition />

    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition Height="50*" />

    </Grid.RowDefinitions>

    <Button x:Name="btnConfirmCopy" Content="Confirm Copy" Grid.Row="0" Grid.Column="0" Style="{DynamicResource style_Button}" Click="btnConfirmCopy_Click" />
    <Button x:Name="btnBack" Content="Back" Grid.Row="0" Grid.Column="1" Style="{DynamicResource style_Button}" Click="btnBack_Click" />

    </Grid>

    <!--<Border Style="{StaticResource style_ButtonBorder}" x:Name="btn_ConfirmCopy" Grid.Column="0" Grid.Row="0" HorizontalAlignment="Left">

    <Button x:Name="btnConfirmCopy" Content="Confirm Copy" Click="btnCopy_Click" Grid.Row="4" Grid.Column="1" Style="{StaticResource style_Button}" />
    </Border>-->

    <Border Style="{DynamicResource style_NormalBorder}" x:Name="RtfBorder" Grid.Column="2" Grid.Row="2" Grid.ColumnSpan="2" Grid.RowSpan="2" >


    <igDP:XamDataGrid Name="dgConfirmCopy"
    DataSource="{Binding}"
    SortRecordsByDataType="False"
    Margin="5,5,5,5"
    InitializeRecord="dgConfirmCopy_InitializeRecord"
    AutoFit="True" >


    <igDP:XamDataGrid.Resources>
    <!-- This Style puts a CheckBox into the record selectors. -->
    <Style TargetType="{x:Type igDP:RecordSelector}" x:Key="RecordSelectorStyle1">
    <Setter Property="Template">
    <Setter.Value>
    <ControlTemplate TargetType="{x:Type igDP:RecordSelector}">
    <CheckBox HorizontalAlignment="Center"
    VerticalAlignment="Center"
    x:Name="chkRecordSelector"
    IsChecked="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Record.IsSelected, Mode=TwoWay}"/>
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    </Style>
    <!--<Style x:Key="GroupByRecordPresenterStyle" TargetType="{x:Type igDP:GroupByRecordPresenter}">
    <Setter Property="FontSize" Value="12"></Setter>
    <Setter Property="FontWeight" Value="Bold"></Setter>
    <Setter Property="Height" Value="30"></Setter>
    <Setter Property="Foreground" Value="#005290"></Setter>
    <Setter Property="BorderBrush" Value="Transparent"></Setter>
    <Setter Property="BorderThickness" Value="0"></Setter>
    <Setter Property="Margin" Value="5,5,5,5"></Setter>

    </Style>-->

    <Style x:Key="GroupByRecordPresenterStyle" TargetType="{x:Type igDP:GroupByRecordPresenter}">

    <Setter Property="Background" Value="#00FFFFFF"/>
    <!--<Setter Property="Margin" Value="0,0,0,2"/>-->
    <Setter Property="Height" Value="30"/>
    <Setter Property="FontSize" Value="12"></Setter>
    <Setter Property="FontWeight" Value="Bold"></Setter>
    <Setter Property="Foreground" Value="#005290"></Setter>
    <Setter Property="BorderBrush" Value="Transparent"></Setter>
    <Setter Property="BorderThickness" Value="0"></Setter>
    <!--<Setter Property="Margin" Value="1,1,1,1"></Setter>-->
    <Setter Property="Template">
    <Setter.Value>
    <ControlTemplate TargetType="{x:Type igDP:GroupByRecordPresenter}">
    <ControlTemplate.Resources>
    <Storyboard x:Key="sbDisplayNested">
    <DoubleAnimationUsingKeyFrames
    BeginTime="00:00:00"
    Storyboard.TargetName="ncpVisual"
    Storyboard.TargetProperty="Opacity"
    FillBehavior="HoldEnd">
    <DiscreteDoubleKeyFrame Value="0" KeyTime="00:00:00"/>
    <DiscreteDoubleKeyFrame Value="0" KeyTime="00:00:00.25"/>
    <SplineDoubleKeyFrame KeySpline="0.5,0.5,0.5,0.5" Value="1" KeyTime="00:00:0.75"/>
    </DoubleAnimationUsingKeyFrames>
    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ncpVisual" Storyboard.TargetProperty="(UIElement.Visibility)">
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Visible}" KeyTime="00:00:00"/>
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Collapsed}" KeyTime="00:00:0.75"/>
    </ObjectAnimationUsingKeyFrames>
    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ncpMask" Storyboard.TargetProperty="(UIElement.Visibility)">
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Visible}" KeyTime="00:00:00"/>
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Collapsed}" KeyTime="00:00:0.75"/>
    </ObjectAnimationUsingKeyFrames>
    </Storyboard>
    <Storyboard x:Key="sbHideNested">
    <DoubleAnimationUsingKeyFrames
    BeginTime="00:00:00"
    Storyboard.TargetName="NestedContentPresenter"
    Storyboard.TargetProperty="Opacity"
    FillBehavior="HoldEnd">
    <SplineDoubleKeyFrame KeySpline="0.5,0.5,0.5,0.5" Value="1" KeyTime="00:00:00.15"/>
    </DoubleAnimationUsingKeyFrames>
    </Storyboard>
    </ControlTemplate.Resources>
    <Grid Background="{TemplateBinding Background}">
    <Grid.ColumnDefinitions>
    <ColumnDefinition Width="Auto"/>
    <ColumnDefinition Width="*"/>
    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition x:Name="row0" Height="Auto"/>
    <RowDefinition x:Name="row1" Height="Auto"/>
    <RowDefinition x:Name="row2" Height="*"/>
    </Grid.RowDefinitions>
    <!-- Row for nested content -->
    <!-- Expansion Checkbox -->
    <!-- AS 1/27/09 NA 2009 Vol 1 - Set ZIndex and RenderTransform for fixed fields -->
    <!-- AS 6/3/09 NA 2009 Vol 2 - Added Command(Parameter) & ToggleMode to support undo/redo -->
    <igDPWindows:ExpansionIndicator x:Name="ExpansionIndicator"
    RenderTransform="{TemplateBinding FixedNearElementTransform}"
    Panel.ZIndex="1"
    Grid.Row="1"
    Visibility="{TemplateBinding ExpansionIndicatorVisibility}"
    Command="{x:Static igDP:DataPresenterCommands.ToggleRecordIsExpanded}"
    CommandParameter="{TemplateBinding Record}"
    ToggleMode="Manual"
    />
    <!--IsChecked="{Binding Path=IsExpanded, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"-->
    <!-- JJD 10/10/12 - TFS123036
    Added HeaderContentBackground so that the header area would span the entire width of the GroupByPresenter -->
    <Rectangle
    x:Name="HeaderContentBackground"
    Fill="{DynamicResource {ComponentResourceKey TypeInTargetAssembly={x:Type igDP:XamDataGrid}, ResourceId=LabelBackground}}"
    Grid.Row="0"
    Grid.Column="0"
    Grid.ColumnSpan="2"
    HorizontalAlignment="Stretch"
    VerticalAlignment="Stretch"/>
    <!-- JJD 6/4/09 - TFS17060 - Added Header site to support HeaderPlacementInGroupBy 'OnTop' in reporting -->
    <ContentPresenter
    x:Name="PART_HeaderContentSite"
    Grid.Row="0"
    Grid.Column="1"
    Content="{TemplateBinding HeaderContent}"
    Visibility="{Binding Path=HasHeaderContent, RelativeSource={RelativeSource TemplatedParent}}"
    HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
    VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
    />

    <!-- Record content site -->
    <!-- AS 1/27/09 NA 2009 Vol 1 - Set RenderTransform for fixed fields -->
    <Grid
    x:Name="PART_RecordContentSite"
    RenderTransform="{TemplateBinding FixedNearElementTransform}"
    Margin="0"
    Grid.Row="1"
    Grid.Column="1"
    Visibility="Collapsed">

    <StackPanel Orientation="Horizontal">

    <ContentControl

    Content="{Binding Path=Description, RelativeSource={RelativeSource TemplatedParent}}"
    VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
    HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"/>
    <!-- SSP 4/3/08 - Summaries Functionality -->
    <!-- AS 1/27/09 NA 2009 Vol 1 - Set RenderTransform for fixed fields -->
    <igDP:GroupBySummariesPresenter
    RenderTransform="{TemplateBinding ScrollableElementTransform}"
    HorizontalAlignment="Left"
    x:Name="GroupBySummariesPresenter"
    Visibility="Collapsed"
    GroupByRecord="{TemplateBinding Record }"
    />
    </StackPanel>
    </Grid>
    <!-- Nested Content -->
    <Grid
    x:Name="PART_NestedContentSite"
    Grid.Row="2"
    Grid.Column="1"
    Visibility="Collapsed">
    <!-- AS 2/13/09 TFS13978 - Set RenderTransform for fixed fields -->
    <Border
    CornerRadius="0,0,3,3"
    BorderBrush="#44102975"
    BorderThickness="1"
    RenderTransform="{TemplateBinding FixedNearElementTransform}"
    >
    <Border.Background>
    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
    <GradientStop Color="#FFFFFFFF" Offset="0.25"/>
    <GradientStop Color="#FFEEEEEE" Offset="1.2"/>
    </LinearGradientBrush>
    </Border.Background>
    <!-- AS 3/25/09 TFS15801 -->
    <ContentControl
    RenderTransform="{TemplateBinding ScrollableElementTransform}"
    x:Name="NestedContentPresenter"
    Content="{Binding Path=NestedContent, RelativeSource={RelativeSource TemplatedParent}}"
    Margin="0,0,0,5"/>
    </Border>
    <!-- AS 11/14/07 BR26035
    The namescope was broken because the recordlistcontrol was not in the logical tree. We
    need to use a ContentControl instead so the content is made a logical child. -->
    <!-- AS 3/25/09 TFS15801
    This should be nested within the Border above.
    <ContentControl x:Name="NestedContentPresenter" Content="{Binding Path=NestedContent, RelativeSource={RelativeSource TemplatedParent}}" Margin="0,0,0,5"/>-->
    </Grid>
    </Grid>
    <ControlTemplate.Triggers>
    <!-- AS 11/8/11 TFS88111 -->
    <MultiDataTrigger>
    <MultiDataTrigger.Conditions>
    <Condition Binding="{Binding Path=FieldLayout.AutoFitToWidth, RelativeSource={RelativeSource Self}}" Value="True" />
    <Condition Binding="{Binding Path=Orientation, RelativeSource={RelativeSource Self}}" Value="Vertical" />
    </MultiDataTrigger.Conditions>
    <Setter TargetName="PART_HeaderContentSite" Property="Grid.ColumnSpan" Value="2"/>
    <Setter TargetName="PART_RecordContentSite" Property="Grid.ColumnSpan" Value="2"/>
    <Setter TargetName="GroupBySummariesPresenter" Property="HorizontalAlignment" Value="Stretch"/>
    <!-- AS 4/26/13 TFS138379 -->
    <Setter TargetName="PART_HeaderContentSite" Property="HorizontalAlignment" Value="Stretch"/>
    </MultiDataTrigger>

    <Trigger Property="ShouldDisplayGroupByRecordContent" Value="true">
    <Setter TargetName="PART_RecordContentSite" Property="Visibility" Value="Visible"/>
    </Trigger>
    <Trigger Property="ShouldDisplayGroupByRecordContent" Value="false">
    <Setter TargetName="ExpansionIndicator" Property="Visibility" Value="Hidden"/>
    </Trigger>
    <!-- SSP 4/3/08 - Summaries Functionality -->
    <Trigger Property="ShouldDisplaySummaryCells" Value="true">
    <Setter TargetName="GroupBySummariesPresenter" Property="Visibility" Value="Visible"/>
    </Trigger>
    <MultiTrigger>
    <MultiTrigger.Conditions>
    <Condition Property="Orientation" Value="Vertical"/>
    <Condition Property="ShouldDisplayGroupByRecordContent" Value="false"/>
    </MultiTrigger.Conditions>
    <Setter TargetName="ExpansionIndicator" Property="Grid.Row" Value="2"/>
    </MultiTrigger>

    <!-- JJD 1/20/09 - In horizontal mode we need to leave the height on the content area visible -->
    <MultiTrigger>
    <MultiTrigger.Conditions>
    <Condition Property="Orientation" Value="Horizontal"/>
    <Condition Property="ShouldDisplayGroupByRecordContent" Value="false"/>
    </MultiTrigger.Conditions>
    <Setter TargetName="PART_RecordContentSite" Property="Visibility" Value="Visible"/>
    </MultiTrigger>

    <Trigger Property="HasNestedContent" Value="true">
    <Setter TargetName="PART_NestedContentSite" Property="Visibility" Value="Visible"/>
    </Trigger>

    <!-- MD 6/10/10 - ChildRecordsDisplayOrder feature-->
    <MultiDataTrigger>
    <MultiDataTrigger.Conditions>
    <Condition Binding="{Binding Path=FieldLayout.ChildRecordsDisplayOrderResolved}" Value="BeforeParent"/>
    <Condition Binding="{Binding Path=Orientation, RelativeSource={RelativeSource Self}}" Value="Vertical"/>
    </MultiDataTrigger.Conditions>
    <Setter TargetName="PART_NestedContentSite" Property="Grid.Row" Value="0" />
    <Setter TargetName="PART_HeaderContentSite" Property="Grid.Row" Value="1" />
    <!-- JJD 10/10/12 - TFS123036
    Added HeaderContentBackground so that the header area would span the entire width of the GroupByPresenter -->
    <Setter TargetName="HeaderContentBackground" Property="Grid.Row" Value="1" />
    <Setter TargetName="ExpansionIndicator" Property="Grid.Row" Value="2" />
    <Setter TargetName="PART_RecordContentSite" Property="Grid.Row" Value="2" />
    <Setter TargetName="row0" Property="Height" Value="*" />
    <Setter TargetName="row2" Property="Height" Value="Auto" />
    </MultiDataTrigger>

    <!-- MD 8/3/10 - TFS35609 -->
    <MultiDataTrigger>
    <MultiDataTrigger.Conditions>
    <Condition Binding="{Binding Path=FieldLayout.ChildRecordsDisplayOrderResolved}" Value="BeforeParentHeadersAttached"/>
    <Condition Binding="{Binding Path=Orientation, RelativeSource={RelativeSource Self}}" Value="Vertical"/>
    </MultiDataTrigger.Conditions>
    <Setter TargetName="PART_NestedContentSite" Property="Grid.Row" Value="0" />
    <Setter TargetName="PART_HeaderContentSite" Property="Grid.Row" Value="1" />
    <!-- JJD 10/10/12 - TFS123036
    Added HeaderContentBackground so that the header area would span the entire width of the GroupByPresenter -->
    <Setter TargetName="HeaderContentBackground" Property="Grid.Row" Value="1" />
    <Setter TargetName="ExpansionIndicator" Property="Grid.Row" Value="2" />
    <Setter TargetName="PART_RecordContentSite" Property="Grid.Row" Value="2" />
    <Setter TargetName="row0" Property="Height" Value="*" />
    <Setter TargetName="row2" Property="Height" Value="Auto" />
    </MultiDataTrigger>

    </ControlTemplate.Triggers>
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    <Setter Property="TemplateCardView">
    <Setter.Value>
    <ControlTemplate TargetType="{x:Type igDP:GroupByRecordPresenter}">
    <ControlTemplate.Resources>
    <Storyboard x:Key="sbDisplayNested">
    <DoubleAnimationUsingKeyFrames
    BeginTime="00:00:00"
    Storyboard.TargetName="ncpVisual"
    Storyboard.TargetProperty="Opacity"
    FillBehavior="HoldEnd">
    <DiscreteDoubleKeyFrame Value="0" KeyTime="00:00:00"/>
    <DiscreteDoubleKeyFrame Value="0" KeyTime="00:00:00.25"/>
    <SplineDoubleKeyFrame KeySpline="0.5,0.5,0.5,0.5" Value="1" KeyTime="00:00:0.75"/>
    </DoubleAnimationUsingKeyFrames>
    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ncpVisual" Storyboard.TargetProperty="(UIElement.Visibility)">
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Visible}" KeyTime="00:00:00"/>
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Collapsed}" KeyTime="00:00:0.75"/>
    </ObjectAnimationUsingKeyFrames>
    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ncpMask" Storyboard.TargetProperty="(UIElement.Visibility)">
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Visible}" KeyTime="00:00:00"/>
    <DiscreteObjectKeyFrame Value="{x:Static Visibility.Collapsed}" KeyTime="00:00:0.75"/>
    </ObjectAnimationUsingKeyFrames>
    </Storyboard>
    <Storyboard x:Key="sbHideNested">
    <DoubleAnimationUsingKeyFrames
    BeginTime="00:00:00"
    Storyboard.TargetName="NestedContentPresenter"
    Storyboard.TargetProperty="Opacity"
    FillBehavior="HoldEnd">
    <SplineDoubleKeyFrame KeySpline="0.5,0.5,0.5,0.5" Value="1" KeyTime="00:00:00.15"/>
    </DoubleAnimationUsingKeyFrames>
    </Storyboard>
    </ControlTemplate.Resources>
    <Grid Background="{TemplateBinding Background}">
    <Grid.ColumnDefinitions>
    <ColumnDefinition Width="*" MinWidth="20"/>
    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition Height="Auto"/>
    <RowDefinition Height="*"/>
    </Grid.RowDefinitions>
    <!-- Row for nested content -->
    <!-- Record content site -->
    <Grid
    x:Name="PART_RecordContentSite"
    Margin="0"
    Grid.Row="1"
    Grid.Column="0"
    Visibility="Collapsed"
    >
    <!-- Background Bar -->
    <Border
    HorizontalAlignment="Stretch"
    VerticalAlignment="Stretch"
    Width="Auto"
    Height="Auto"
    RenderTransformOrigin="0.5,0.5"
    CornerRadius="2,2,2,2"
    SnapsToDevicePixels="True"
    Background="{DynamicResource {ComponentResourceKey TypeInTargetAssembly={x:Type igDP:XamDataGrid}, ResourceId=LabelBackground}}">
    <Grid Margin="0,0,0,0" Width="Auto" Height="Auto">
    <Rectangle
    Stroke="#44000000"
    StrokeThickness="1"
    RadiusX="1.55015910897703"
    RadiusY="1.55015910897703"
    Fill="Transparent"/>
    <Rectangle
    Margin="1"
    Stroke="#44FFFFFF"
    StrokeThickness="1"
    RadiusX="0.550159108977027"
    RadiusY="0.550159108977027"
    Fill="Transparent"/>
    </Grid>
    </Border>
    <!-- End Background Bar -->
    <Border
    x:Name="highlight"
    HorizontalAlignment="Stretch"
    VerticalAlignment="Stretch"
    Width="Auto"
    Height="Auto"
    CornerRadius="2,2,2,2"
    Background="{DynamicResource {ComponentResourceKey TypeInTargetAssembly={x:Type igDP:XamDataGrid}, ResourceId=LabelHighlight}}">
    <Grid Margin="0,0,0,0" Width="Auto" Height="Auto">
    <Rectangle
    Stroke="#44000000"
    StrokeThickness="1"
    RadiusX="1.55015910897703"
    RadiusY="1.55015910897703"
    Fill="Transparent"/>
    <Rectangle
    Margin="1"
    Stroke="#44FFFFFF"
    StrokeThickness="1"
    RadiusX="0.550159108977027"
    RadiusY="0.550159108977027"
    Fill="Transparent"/>
    </Grid>
    </Border>
    <!-- End Add 8/1/2006 GH-->
    <!-- Label Text -->
    <StackPanel Orientation="Vertical">
    <ContentControl
    Style="{StaticResource ControlHeaderLabel}"
    Content="{Binding Path=Description, RelativeSource={RelativeSource TemplatedParent}}"
    VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
    HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"/>
    <!-- SSP 4/3/08 - Summaries Functionality -->
    <igDP:GroupBySummariesPresenter
    Grid.Row="1"
    HorizontalAlignment="Left"
    x:Name="GroupBySummariesPresenter"
    Visibility="Collapsed"
    GroupByRecord="{TemplateBinding Record}"/>
    </StackPanel>
    </Grid>
    <!-- Nested Content -->
    <Grid
    x:Name="PART_NestedContentSite"
    Grid.Row="1"
    Grid.Column="0"
    Visibility="Collapsed">
    <!--<igWindows:NestedContentBackground/>-->
    <Border CornerRadius="0,0,3,3" BorderBrush="#44102975" BorderThickness="1">
    <Border.Background>
    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
    <GradientStop Color="#FFFFFFFF" Offset="0.25"/>
    <GradientStop Color="#FFEEEEEE" Offset="1.2"/>
    </LinearGradientBrush>
    </Border.Background>
    <!-- AS 3/25/09 TFS15801 -->
    <ContentControl x:Name="NestedContentPresenter" Content="{Binding Path=NestedContent, RelativeSource={RelativeSource TemplatedParent}}" Margin="0,0,0,5"/>
    </Border>
    <!-- AS 11/14/07 BR26035
    The namescope was broken because the recordlistcontrol was not in the logical tree. We
    need to use a ContentControl instead so the content is made a logical child. -->
    <!-- AS 3/25/09 TFS15801
    This should be nested within the Border above.
    <ContentControl x:Name="NestedContentPresenter" Content="{Binding Path=NestedContent, RelativeSource={RelativeSource TemplatedParent}}" Margin="0,0,0,5"/>-->
    </Grid>
    </Grid>
    <ControlTemplate.Triggers>
    <Trigger Property="ShouldDisplayGroupByRecordContent" Value="true">
    <Setter TargetName="PART_RecordContentSite" Property="Visibility" Value="Visible"/>
    </Trigger>
    <!--<Trigger Property="ShouldDisplayGroupByRecordContent" Value="false"/>-->
    <!-- SSP 4/3/08 - Summaries Functionality -->
    <Trigger Property="ShouldDisplaySummaryCells" Value="true">
    <Setter TargetName="GroupBySummariesPresenter" Property="Visibility" Value="Visible"/>
    </Trigger>
    <Trigger Property="HasNestedContent" Value="true">
    <Setter TargetName="PART_NestedContentSite" Property="Visibility" Value="Visible"/>
    </Trigger>
    </ControlTemplate.Triggers>
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    </Style>

    </igDP:XamDataGrid.Resources>
    <!--HeaderPrefixAreaStyle="{StaticResource HeaderPrefixAreaStyle1}-->
    <!--<igDP:XamDataGrid.FieldLayoutSettings>
    <igDP:FieldLayoutSettings AutoGenerateFields="False" RecordSelectorStyle="{StaticResource RecordSelectorStyle1}" />
    </igDP:XamDataGrid.FieldLayoutSettings>-->

    <igDP:XamDataGrid.FieldLayouts >
    <igDP:FieldLayout>
    <igDP:FieldLayout.Settings >
    <igDP:FieldLayoutSettings AllowFieldMoving="No"
    AllowDelete="False"
    AutoGenerateFields="False"
    AutoFitMode="ExtendLastField"
    SelectionTypeRecord="Single"
    FilterUIType="LabelIcons"
    GroupByExpansionIndicatorVisibility="Visible"
    >
    </igDP:FieldLayoutSettings>
    </igDP:FieldLayout.Settings>
    <igDP:FieldLayout.Fields >

    <igDP:Field Name="Observation" Label="Observation" Width="200*" >
    <igDP:Field.Settings>
    <igDP:FieldSettings LabelPresenterStyle="{StaticResource ColumnHeader}" AllowEdit="False" />

    </igDP:Field.Settings>

    </igDP:Field>
    <igDP:Field Name="Value" Label="Charted value" Width="500*" >
    <igDP:Field.Settings>
    <igDP:FieldSettings LabelPresenterStyle="{StaticResource ColumnHeader}" AllowEdit="False" />

    </igDP:Field.Settings>

    </igDP:Field>
    <!--<igDP:Field Name="ParameterGUID" Label="ParameterGUID" Visibility="Hidden"></igDP:Field>-->
    <igDP:Field Name="Section" Label="Section" Visibility="Hidden"></igDP:Field>
    <igDP:Field Name="Set" Label="Set" Visibility="Hidden"/>

    </igDP:FieldLayout.Fields>
    <igDP:FieldLayout.SortedFields >
    <igDP:FieldSortDescription FieldName="Section" IsGroupBy="True" ></igDP:FieldSortDescription>
    <igDP:FieldSortDescription FieldName="Set" IsGroupBy="True"></igDP:FieldSortDescription>
    </igDP:FieldLayout.SortedFields>

    </igDP:FieldLayout>

    </igDP:XamDataGrid.FieldLayouts>

    <igDP:XamDataGrid.FieldSettings >
    <igDP:FieldSettings GroupByRecordPresenterStyle="{StaticResource GroupByRecordPresenterStyle}" />

    </igDP:XamDataGrid.FieldSettings >

    </igDP:XamDataGrid>

    <!--**********************************************************************************-->
    <!--<StackPanel Style="{DynamicResource style_StackPanel}">
    <Label Content="Charted Values" Name="lbl_ChartedValues" Grid.Column="2" Grid.Row="2" Grid.ColumnSpan="2" Style="{DynamicResource HeaderLabel}" />
    <xctk:RichTextBox x:Name="rtf_DisplayObservationValues" Grid.Row="3" Grid.Column="2" Grid.ColumnSpan="2"
    ScrollViewer.VerticalScrollBarVisibility="Auto" Style="{DynamicResource style_RTF}" Grid.RowSpan="2">

    </xctk:RichTextBox>

    </StackPanel>-->
    </Border>
    </Grid>
    </Border>
    </TabItem>
    </TabControl>

Children