# New-OfficeEmailMailboxReaderOptions

Creates bounded mbox reader settings through ordinary PowerShell parameters.

Cmdlet 

**Module**

`PSWriteOffice`

**Inputs**

`OfficeIMO.Email.EmailReaderOptions`

**Outputs**

`OfficeIMO.Email.EmailMailboxReaderOptions`

**Source**

[NewOfficeEmailMailboxReaderOptionsCommand.cs:16](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/PowerShell/PSWriteOffice/Sources/PSWriteOffice/Cmdlets/Email/NewOfficeEmailMailboxReaderOptionsCommand.cs#L16) 

Creates bounded mbox reader settings through ordinary PowerShell parameters.

## Syntax

```
New-OfficeEmailMailboxReaderOptions
[-MaxMailboxBytes <Int64>]
[-MaxMessageCount <Int32>]
[-MessageOptions <EmailReaderOptions>]
[-Variant <Auto|Mboxo|Mboxrd>]
[<CommonParameters>]
```

[#](#method-new-officeemailmailboxreaderoptions-int64-int32-emailreaderoptions-mboxvariant)

Parameter set: `Options`

## Guides & Samples

Authored walkthroughs and practical samples linked to this command.

- [Open Formats and Text Automation](/docs/pswriteoffice/open-text-formats/) Guide
  
  Use the smaller PSWriteOffice families for text, interchange, open formats, and managed message workflows. Includes examples and cmdlet links.
- [Read and Convert PST, OST, and Mailbox Stores](/docs/email/mailbox-stores/) Guide
  
  Open PST, OST, OLM, mbox, EMLX, Apple Mail, and Maildir stores, export their messages, and convert a store to a new PST with verification.

## Examples

### Read a bounded mailbox with a reusable per-message policy.

```powershell
$messageOptions = New-OfficeEmailReaderOptions -ExcludeAttachmentContent
$options = New-OfficeEmailMailboxReaderOptions -MessageOptions $messageOptions -MaxMessageCount 5000
Get-OfficeEmailMailbox -Path .\Archive.mbox -Options $options -AsResult
```

## Parameters

**-MaxMailboxBytes Int64 optional**

Maximum aggregate source bytes consumed from one mailbox.

**-MaxMessageCount Int32 optional**

Maximum messages in one mailbox.

**-MessageOptions EmailReaderOptions optionalpipeline: True (ByValue)**

Bounded policy applied independently to each message.

**-Variant MboxVariant optional**

Escaping convention to decode.

Possible values: `Auto`, `Mboxo`, `Mboxrd`

## Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see [about_CommonParameters](https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_commonparameters).

<!-- PowerForge markdown artifact sha256:4AAD19369AA61638A9E2DFC2C263454A0ADCB4E01005CABBE7EEB1331B211BB2 -->
