FirstPageHeader: IEaxHeader;
FirstPageHeader: Prognoz.Platform.Interop.Express.IEaxHeader;
The FirstPageHeader property returns parameters of the first page header.
To get parameters of the first page footer, use the IEaxHeaders.FirstPageFooter property.
To use settings of particular header or footer for the first page, use the IEaxHeaders.DifferentFirstPageHeaderFooter property.
Executing the example requires that the repository contains express report with the EXPRESS identifier.
Add links to the Express, Metabase system assemblies.
Sub UserProc;
Var
Metabase: IMetabase;
Express : IEaxAnalyzer;
Headers: IEaxHeaders;
Param: IEaxHeader;
Begin
Metabase := MetabaseClass.Active;
Express := Metabase.ItemById("EXPRESS").Edit As IEaxAnalyzer;
Headers := Express.HeadersFooters;
// Set up indent of header and footers for the first page
Param := Headers.FirstPageHeader;
Param.Margin := 30;
Param := Headers.FirstPageFooter;
Param.Margin := 30;
// Take into account settings for the first page
Headers.DifferentFirstPageHeaderFooter := True;
Debug.Writeline("Indent of the first page header: " +
Headers.FirstPageHeader.Margin.ToString);
Debug.Writeline("Indent of the first page footer: " +
Headers.FirstPageFooter.Margin.ToString);
(Express As IMetabaseObject).Save;
End Sub UserProc;
Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.Express;
…
Public Shared Sub Main(Params: StartParams);
Var
Metabase: IMetabase;
Express : IEaxAnalyzer;
Headers: IEaxHeaders;
Param: IEaxHeader;
Begin
Metabase := Params.Metabase;
Express := Metabase.ItemById["EXPRESS"].Edit() As IEaxAnalyzer;
Headers := Express.HeadersFooters;
// Set up indent of header and footers for the first page
Param := Headers.FirstPageHeader;
Param.Margin := 30;
Param := Headers.FirstPageFooter;
Param.Margin := 30;
// Take into account settings for the first page
Headers.DifferentFirstPageHeaderFooter := True;
System.Diagnostics.Debug.Writeline("The first page header indent: " +
Headers.FirstPageHeader.Margin.ToString());
System.Diagnostics.Debug.Writeline("The first page footer indent: " +
Headers.FirstPageFooter.Margin.ToString());
(Express As IMetabaseObject).Save();
End Sub;
After executing the example indent parameters of the first page headers and footers will be determined. The console displays information about header and footer indents.
See also: