Current filter:
                                You should refresh the page.
                                  • [DevExpress Support Team: CLONED FROM T818884: How to combine multiple GridControls for print preview]

                                    Hi Janet,
                                    So, I have been playing around with links, and saw that I could add a custom PageHeaderTemplate to create a header for my gridcontrol.
                                    But, I am not able to make it work. Here's my xaml, and my code behind:

                                    <dxdo:DocumentPanel x:Name="HeatersTab" Caption="Heaters"> <dxg:GridControl Name="HeatersGridControl" AutoGenerateColumns="None" EnableSmartColumnsGeneration="True" ItemsSource="{Binding ListOfHeaters}"> <dxg:GridColumn HorizontalHeaderContentAlignment="Center" Width="100" Header="Quantity" FieldName="NumberOfParts" AllowColumnFiltering="False" AllowSorting="True" > <dxg:GridColumn.EditSettings> <dxe:TextEditSettings HorizontalContentAlignment="Center"/> </dxg:GridColumn.EditSettings> </dxg:GridColumn> <dxg:GridColumn HorizontalHeaderContentAlignment="Center" Width="200" FieldName="PartNumber" AllowColumnFiltering="False" AllowSorting="True" > <dxg:GridColumn.EditSettings> <dxe:TextEditSettings HorizontalContentAlignment="Center"/> </dxg:GridColumn.EditSettings> </dxg:GridColumn> <dxg:GridColumn HorizontalHeaderContentAlignment="Center" Width="320" FieldName="Description" AllowColumnFiltering="False" AllowSorting="False" /> <dxg:GridControl.Resources> <DataTemplate x:Key="CustomPrintHeaderTemplate"> <Grid Width="{Binding Path=Content.(dxg:GridPrintingHelper.PrintRowInfo).TotalHeaderWidth}"> <TextBlock Text="Title Block 3" TextAlignment="Center" dxp:ExportSettings.TargetType="Text"/> </Grid> </DataTemplate> <Style TargetType="dxg:GridColumn"> <Setter Property="HeaderStyle"> <Setter.Value> <Style TargetType="dxg:BaseGridHeader"> <Setter Property="FontWeight" Value="Bold"/> <Setter Property="Background" Value="Beige"></Setter> </Style> </Setter.Value> </Setter> </Style> </dxg:GridControl.Resources> <dxg:GridControl.View> <dxg:TableView AllowPerPixelScrolling="True" ShowGroupPanel="False" /> </dxg:GridControl.View> </dxg:GridControl> </dxdo:DocumentPanel> List<TemplatedLink> links = new List<TemplatedLink>(); var customlink = new PrintableControlLink((TableView)HeatersGridControl.View); link.PageHeaderTemplate = (DataTemplate)HeatersGridControl.Resources["CustomPrintHeaderTemplate"]; links.Add(customlink); links.Add(new PrintableControlLink((TableView)InsulatorsGridControl.View)); links.Add(new PrintableControlLink((TableView)ExtensionsGridControl.View)); CompositeLink compositeLink = new CompositeLink(links); PrintHelper.ShowRibbonPrintPreview(this, compositeLink);

                                1 Solution

                                Creation Date Importance Sort by

                                To print an individual header and footer for each grid control, use the ReportHeaderTemplate / ReportFooterTemplate properties of the PrintableControlLink.
                                One more solution is to put an instance of a SimpleLink before and after each PrintableControlLink to "wrap" a printable control into a header and footer.
                                Let me know if I can be of further help.

                                We discussed this case in the past:
                                How to print multiple grids with header and footer using CompositeLink
                                WPF CompositeLink Collection of links print their own page header or page footer

                                • Customer61282 10.01.2019

                                  Hi Janet,
                                  Thank you.
                                  That is exactly what I needed.

                                  Although, this link does not point to anything:
                                  WPF CompositeLink Collection of links print their own page header or page footer

                                • Jannet (DevExpress Support) 10.02.2019

                                  You're always welcome!

                                  >Although, this link does not point to anything:
                                  WPF CompositeLink Collection of links print their own page header or page footer

                                  It is strange - I've just checked this link and got it correctly pointing to the ticket. Do you mean that you can't see the ticket?

                                • Customer61282 10.02.2019

                                  Hi Janet,
                                  The link is not broken per se. It does take you to a page.
                                  But, there is nothing helpful in the solution section. It only says this or that is not supported.Hence, not pointing to any samples or anything that can help.

                                • Jannet (DevExpress Support) 10.03.2019

                                  Thank you for the clarification. I understand your point.

                                  Should you have any further questions, feel free to contact us.