Table of Contents

CompoundFileVersion Enum

Definition

Namespace
Bodu.IO.Compound
Assembly
Bodu.IO.Compound.dll
Package
Bodu.IO.Compound 1.3.0
Source
CompoundFileVersion.cs

Specifies the compound-file format version, which determines the sector size used when writing.

public enum CompoundFileVersion
Extension Methods

Fields

V3 = 3

Version 3, using 512-byte sectors. This is the most widely compatible layout and the default.

[MS-CFB] 2.9 limits a version-3 file to 2 GB, so writing a tree whose container would be larger throws CompoundFileSerializationException before any byte is written.

V4 = 4

Version 4, using 4096-byte sectors, suited to larger containers.

A version-4 container that passes 2 GB keeps the range lock sector [MS-CFB] 2.8 reserves (sector 0x7FFFE, which covers file offsets 0x7FFFFF00-0x7FFFFFFF) free of data: the writer marks it ENDOFCHAIN in the FAT, writes it as zeros, and places the sector that would have taken it, and every sector after, one sector later, so no chain passes through it.

Applies to

ProductVersions
.NET8, 10