バージョン

PagePresenterStyle プロパティ (ReportSection)

ReportPagePresenter のスタイルを取得または設定します
シンタックス
'宣言
 
Public Property PagePresenterStyle As Style
public Style PagePresenterStyle {get; set;}
解説

注: このプロパティは、ReportBaseReportBase.PagePresenterStyle 設定を優先させます。

使用例
Now apply the style to page layout
Private Sub SetPresenterStyle()
    Dim reportObj As New Report()
    Dim section As New EmbeddedVisualReportSection(XamDataGrid1)
    
    ' apply keyed style to page layout
    section.PagePresenterStyle = TryCast(root.TryFindResource("PagePresenterStyle"), Style)
    reportObj.Sections.Add(section)
    
    reportObj.Print(False)
End Sub
Now apply the style to page layout
private void SetPresenterStyle()
{
	Report reportObj = new Report();
	EmbeddedVisualReportSection section = new EmbeddedVisualReportSection(XamDataGrid1);

	// apply keyed style to page layout
	section.PagePresenterStyle = root.TryFindResource("PagePresenterStyle") as Style;
	reportObj.Sections.Add(section);

	reportObj.Print(false);
}
<Page  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"  
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
xmlns:igRep="http://infragistics.com/Reporting"  

>
<Page.Resources>

        <Style x:Key="P
agePresenterStyle" TargetType="{x:Type igRep:ReportPagePresenter}">
            <Setter Property="
Template">
                <Setter.Value>

                    
<ControlTemplate TargetType="{x:Type igRep:ReportPagePresenter}">
                        <DockPanel>
                            <StackPanel DockPanel.Dock="Top">
                                <Image Source="../../images\HeaderPic.png"/>
                            </StackPanel>
                            <Grid DockPanel.Dock="Left">
                                <Ellipse Margin="10,0,0,0" Width="50" Stroke="#FFC
FD0E6">
                                    <Ellipse.Fill>

                                        
<RadialGradientBrush SpreadMethod="Pad">
                                            <GradientStop Color="#FF10579D" Offset="0.103"/>
                                            <GradientStop Color="#FFDEE5EE" Offset="1"/>
                                        </R
adialGradientBrush>
                                    </Ellipse.Fill>
                                </Ellipse>

                                <Label Foreground="Beige" Margin="10,0,0,0" Height="50"  Content="{TemplateBinding PhysicalPageNumber}" Padding="0" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" />

                            
</Grid>
                            
<Grid DockPanel.Dock="Right">
                                
<Image VerticalAlignment="Center" Stretch="None" Source="../../images\misc\forward.png"/>
                            
</Grid>
                            
<Grid>
                                
<ContentPresenter x:Name="PART_Content" ContentSource="Content"/>
                            
</Grid>
                        
</DockPanel>
                    
</ControlTemplate>
                
</Setter.Value>
            
</Setter>
        
</Style>

        
</Page.Resources>
</Page>
参照