# PdfRunningContentContext

Read-only page information used to compose bounded running header or footer content.

Class 

`OfficeIMO.Pdf`

**Namespace**

`OfficeIMO.Pdf`

**Assembly**

`OfficeIMO.Pdf`

**Source revision**

`1d5ef38d1e0b` with working tree changes

**Source**

[PdfRunningContentContext.cs:42](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L42)

**Modifiers**

sealed

Read-only page information used to compose bounded running header or footer content.

## Inheritance

- object
- PdfRunningContentContext

## Usage

Explore 6 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Accepted by parameters 6

- Method [PdfFooterBuilder.Content](/api/pdf/officeimo-pdf-pdffooterbuilder/#method-content-func-officeimo-pdf-pdfrunningcontentcontext-system-action-officeimo-pdf-pdfcontentbuilder-officeimo-officelength) parameter `build`
- Method [PdfFooterBuilder.EvenPagesContent](/api/pdf/officeimo-pdf-pdffooterbuilder/#method-evenpagescontent-func-officeimo-pdf-pdfrunningcontentcontext-system-action-officeimo-pdf-pdfcontentbuilder-officeimo-officelength) parameter `build`
- Method [PdfFooterBuilder.FirstPageContent](/api/pdf/officeimo-pdf-pdffooterbuilder/#method-firstpagecontent-func-officeimo-pdf-pdfrunningcontentcontext-system-action-officeimo-pdf-pdfcontentbuilder-officeimo-officelength) parameter `build`
- Method [PdfHeaderBuilder.Content](/api/pdf/officeimo-pdf-pdfheaderbuilder/#method-content-func-officeimo-pdf-pdfrunningcontentcontext-system-action-officeimo-pdf-pdfcontentbuilder-officeimo-officelength) parameter `build`
- Method [PdfHeaderBuilder.EvenPagesContent](/api/pdf/officeimo-pdf-pdfheaderbuilder/#method-evenpagescontent-func-officeimo-pdf-pdfrunningcontentcontext-system-action-officeimo-pdf-pdfcontentbuilder-officeimo-officelength) parameter `build`
- Method [PdfHeaderBuilder.FirstPageContent](/api/pdf/officeimo-pdf-pdfheaderbuilder/#method-firstpagecontent-func-officeimo-pdf-pdfrunningcontentcontext-system-action-officeimo-pdf-pdfcontentbuilder-officeimo-officelength) parameter `build`

Filter members 

Show inherited

## Methods

`public string FormatPageNumber(int number, PdfPageNumberStyle? style = null)` [#](#method-formatpagenumber-int32-nullable-officeimo-pdf-pdfpagenumberstyle)

[PdfRunningContentContext.cs:42](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L42)

Formats a positive page count using the supplied style or this page's numbering style.

Parameters

**number int required**

**style OfficeIMO.Pdf.PdfPageNumberStyle? = null optional**

Returns

`string`

## Inherited Methods

`public virtual bool Equals(object? obj)` [#](#method-equals-object)

Inherited from object

Parameters

**obj object? required**

Returns

`bool`

`public virtual int GetHashCode()` [#](#method-gethashcode)

Inherited from object

Returns

`int`

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public virtual string? ToString()` [#](#method-tostring)

Inherited from object

Returns

`string?`

## Properties

`public int PageNumber { get; }` [#](#property-pagenumber)

[PdfRunningContentContext.cs:21](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L21)

Current visible page number, including an explicitly restarted numbering sequence.

`public int TotalPages { get; }` [#](#property-totalpages)

[PdfRunningContentContext.cs:23](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L23)

Last visible page number in the current numbering sequence, matching the existing {pages} token.

`public int DocumentPageNumber { get; }` [#](#property-documentpagenumber)

[PdfRunningContentContext.cs:25](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L25)

Current one-based physical output page number.

`public int DocumentPages { get; }` [#](#property-documentpages)

[PdfRunningContentContext.cs:27](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L27)

Total physical pages in the document.

`public int SectionPageNumber { get; }` [#](#property-sectionpagenumber)

[PdfRunningContentContext.cs:29](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L29)

Current one-based physical page within the tracked source section, or the PDF page group when no source sections are tracked.

`public int SectionPages { get; }` [#](#property-sectionpages)

[PdfRunningContentContext.cs:31](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L31)

Physical page count in the tracked source section or PDF page group, independent of visible numbering and restarts.

`public OfficeLength ContentWidth { get; }` [#](#property-contentwidth)

[PdfRunningContentContext.cs:33](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L33)

Width of the page's content frame in points, including mirrored margins.

`public OfficeLength PageWidth { get; }` [#](#property-pagewidth)

[PdfRunningContentContext.cs:35](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L35)

Physical page width in points.

`public OfficeLength PageHeight { get; }` [#](#property-pageheight)

[PdfRunningContentContext.cs:37](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L37)

Physical page height in points.

`public PdfPageNumberStyle PageNumberStyle { get; }` [#](#property-pagenumberstyle)

[PdfRunningContentContext.cs:39](https://github.com/EvotecIT/OfficeIMO/blob/1d5ef38d1e0bc45ee35fa9829701a5d52fd16d26/OfficeIMO.Pdf/Model/PdfRunningContentContext.cs#L39)

Number style selected for this page's visible numbering sequence.

<!-- PowerForge markdown artifact sha256:C814320620D5E38D706B54A625186C7F7E2CBC733F64C67927235A60C5D7C6F5 -->
