---
title: "PptxSaveOptions.AsFlatOpc"
url: "https://reference.aspose.com/cells/net/aspose.cells/pptxsaveoptions/asflatopc/"
product: "Aspose.Cells for .NET API Reference"
description: "PptxSaveOptions property. Indicates whether saving as a flat opc file which can be generated by Open XML SDK"
---

## PptxSaveOptions.AsFlatOpc property

Indicates whether saving as a flat opc file which can be generated by Open XML SDK

```csharp
public bool AsFlatOpc { get; set; }
```

### Examples

```csharp
namespace AsposeCellsExamples
{
    using Aspose.Cells;
    using System;

    public class PptxSaveOptionsPropertyAsFlatOpcDemo
    {
        public static void Run()
        {
            // Create a new workbook
            Workbook workbook = new Workbook();

            // Create a sample worksheet
            Worksheet worksheet = workbook.Worksheets[0];

            // Add some data to make the example meaningful
            worksheet.Cells["A1"].Value = "Sample Data";
            worksheet.Cells["A2"].Value = "Flat OPC Demo";

            try
            {
                // Create PptxSaveOptions instance
                PptxSaveOptions saveOptions = new PptxSaveOptions();

                // Display the default value of AsFlatOpc
                Console.WriteLine("Default AsFlatOpc value: " + saveOptions.AsFlatOpc);

                // Set the property to true to demonstrate its usage
                saveOptions.AsFlatOpc = true;
                Console.WriteLine("AsFlatOpc set to: " + saveOptions.AsFlatOpc);

                // Save the workbook as PPTX with the option enabled
                workbook.Save("AsFlatOpcDemo.pptx", saveOptions);

                Console.WriteLine("PPTX saved with AsFlatOpc enabled");
            }
            catch (Exception ex)
            {
                Console.WriteLine($"Error: {ex.Message}");
            }
        }
    }
}
```

### See Also

* class [PptxSaveOptions](../)
* namespace [Aspose.Cells](../../../aspose.cells/)
* assembly [Aspose.Cells](../../../)


