GroupDocs.Parser for .NET

Extract images from ODP using C#

Easily locate and extract embedded images from PDFs, Word documents, Excel sheets, and other file types using GroupDocs.Parser in your .NET apps.

Steps to extract images from Odp in C#

With GroupDocs.Parser, you can extract images from ODP documents in your .NET projects in just a few steps:

  1. Initialize the Parser with the ODP file.
  2. Retrieve image elements from the document.
  3. Use the extracted images as needed in your workflow.
// Open the document containing images using Parser
using (Parser parser = new Parser("input.odp")) {

    // Extract all embedded images from the file
    IEnumerable<PageImageArea> images = parser.GetImages();

    // Handle cases where no images are found
    if (images == null)
    {
        return;
    }

    // Process or save the retrieved images
    foreach (PageImageArea image in images)
    {
        Console.WriteLine(string.Format("Page: {0}, R: {1}, Type: {2}", 
            image.Page.Index, image.Rectangle, image.FileType));
    }
}
dotnet add package GroupDocs.Parser
click to copy
copied
More examples Documentation

Comprehensive document content extraction

GroupDocs.Parser offers more than just image extraction — you can also extract raw text, hyperlinks, metadata, and structured content for advanced automation scenarios.

Image extraction and document parsing workflow

Extract images from multiple formats

Pull out embedded images from a variety of file formats, including DOCX, PDF, PPTX, XLSX, and image files like PNG, JPG, and TIFF.

Preserve original image quality

Images are extracted with high fidelity, maintaining their original resolution, format, and color profile.

Advanced extraction options

Customize image extraction with filtering by page, format, or resolution, and support for multi-page documents.

How to extract and save images from a PDF document

This example demonstrates how to extract all image assets from a PDF file and save them to the local file system.

C#

//  Load the PDF using the Parser class
using (Parser parser = new Parser("input.pdf"))
{
    // Extract embedded images from the file
    IEnumerable<PageImageArea> images = parser.GetImages();

    // Set output format and image options (e.g., PNG)
    ImageOptions options = new ImageOptions(ImageFormat.Png);

    // Write the extracted images to disk
    int imageNumber = 0;
    foreach (PageImageArea image in images)
    {
        image.Save(imageNumber.ToString() + ".png", options);
        imageNumber++;
    }
}

About GroupDocs.Parser for .NET API

GroupDocs.Parser is a robust document parsing library for .NET developers. It allows you to extract images, text, hyperlinks, and structured data from popular file formats like PDF, DOCX, XLSX, PPTX, and others — all without needing any third-party applications.
Learn more
About illustration

Ready to get started?

Download GroupDocs.Parser for free or get a trial license for full access!

Useful resources

Explore documentation, code samples, and community support to enhance your experience.

Supported formats for image extraction

GroupDocs.Parser enables accurate image extraction from a wide range of document and image formats. Check the list below for commonly supported types.

Temporary license tips

1
Sign up with your work email.
Free mail services are not allowed.
2
Use Get a temporary license button on the second step.
 English