Format

Format specifies whether to erase the partition, and which file system to apply to the partition.

Values

NTFS

Formats the partition for the NTFS file system.

When CreatePartitionType is set to Primary or Logical, this is the default file format.

FAT32

Formats the partition for the File Allocation Table (FAT) file system.

When CreatePartitionType is set to EFI, this is the default file format.

When CreatePartition\Type is set to Extended or MSR, the partition does not receive a file format.

When using a disk that already contains an existing partition structure, Format can be used to erase and reformat an existing partition. By default, if an existing partition structure is used, the existing partition is not erased or reformatted.

Valid Configuration Passes

windowsPE

Parent Hierarchy

microsoft-windows-setup- | DiskConfiguration | Disk | ModifyPartitions | ModifyPartition | Format

Applies To

For a list of the supported Windows editions and architectures that this component supports, see microsoft-windows-setup-.

XML Examples

The following XML output for the DiskConfiguration settings shows how to erase and reformat the second partition of a disk.

<DiskConfiguration>

  <Disk wcm:action="add">
    <DiskID>0</DiskID> 

      <ModifyPartition wcm:action="add">
        <Order>1</Order> 
        <PartitionID>2</PartitionID> 
        <Format>NTFS</Format> 
      </ModifyPartition>
    </ModifyPartitions>

</DiskConfiguration>

For full XML examples and recommended partition configurations, see How to Configure UEFI/GPT-Based Hard Disk Partitions or How to Configure BIOS/MBR-Based Hard Disk Partitions.

ModifyPartition