Remove Metadata From PNG File In C#

Remove metadata information from a variety of documents, images, audio & video file formats using GroupDocs.Metadata for .NET API.


Download Free Trial

About GroupDocs.Metadata for .NET API

GroupDocs.Metadata for .NET offers an advanced set of metadata manipulation features, allowing developers to easily read, edit, remove, search, compare, replace and export metadata information from images and document formats without using any external software. Use metadata management API to delete metadata details from PDF, Microsoft Office Word, Excel spreadsheets, PowerPoint presentations, Outlook, OneNote, Visio, Project, AutoCAD, Archive and Multimedia file formats along with many other metadata processing features.

Steps for Removing PNG Metadata in C#

GroupDocs.Metadata for .NET makes it easy for .NET developers to remove metadata details to PNG files from within their applications by implementing a few easy steps.

  • Load PNG with an instance of Metadata class.
  • Use a predicate to find desired metadata properties.
  • Use Metadata.RemoveProperties method to remove the properties.
  • Save the changes back in PNG format.

System Requirements

GroupDocs.Metadata for .NET APIs are supported on all major platforms and operating systems. Before executing the code below, please make sure that you have the following prerequisites installed on your system.

  • Operating Systems: Microsoft Windows, Linux, MacOS
  • Development Environments: Visual Studio, Xamarin, MonoDevelop
  • Frameworks: .NET Framework, .NET Standard, .NET Core, Mono
  • Download the latest version of GroupDocs.Metadata for .NET from NuGet

using (var metadata = new GroupDocs.Metadata.Metadata("input.png"))
{
    // Remove all mentions of any people contributed in file creation
    // Remove all properties with the specified name
    var affected = metadata.RemoveProperties(p => p.Tags.Any(t => t.Category == Tags.Person) || p.Name == "CustomProperty");
    Console.WriteLine("Affected properties: {0}", affected);
    metadata.Save("output.png");
}

Metadata Removal Live Demos

Delete metadata information of PNG file right now by visiting GroupDocs.Metadata Live Demos website. The live demo has the following benefits.

No need to download API

No need to write any code

Just upload the source file

Get download link to save the file

Deleting Metadata Properties From Other File Formats

Multi format documents and images metadata deletion API for .NET. Retrieve metadata of some of the popular file formats as stated below.

Remove ZIP Metadata

(Zipped File)

Remove XLTX Metadata

(Excel Template)

Remove XLTM Metadata

(Excel Macro-Enabled Template)

Remove XLT Metadata

(Excel 97 - 2003 Template)

Remove XLSX Metadata

(Open XML Workbook)

Remove XLSM Metadata

(Macro-enabled Spreadsheet)

Remove XLSB Metadata

(Excel Binary Workbook)

Remove XLS Metadata

(Microsoft Excel Spreadsheet (Legacy))

Remove WMF Metadata

(Windows Metafile)

Remove WEBP Metadata

(Raster Web Image Format)

Remove WAV Metadata

(WAVE Audio File)

Remove VSX Metadata

(Visio Stencil XML File)

Remove VSS Metadata

(Visio Stencil File)

Remove VSDX Metadata

(Visio Drawing)

Remove VSD Metadata

(Visio Drawing File)

Remove VDX Metadata

(The 7th Guest Video File)

Remove TTF Metadata

(TrueType Font)

Remove TTC Metadata

(TrueType Font Collection)

Remove TIFF Metadata

(Tagged Image File Format)

Remove PSD Metadata

(Photoshop Document)

Remove PPTX Metadata

(Open XML presentation Format)

Remove PPTM Metadata

(Macro-enabled Presentation File)

Remove PPT Metadata

(Microsoft PowerPoint 97-2003)

Remove PPSX Metadata

(PowerPoint Slide Show)

Remove PPSM Metadata

(Macro-enabled Slide Show)

Remove PPS Metadata

(PowerPoint Slide Show)

Remove POTX Metadata

(Microsoft PowerPoint Template Presentation)

Remove POTM Metadata

(Microsoft PowerPoint Template File)

Remove POT Metadata

(Microsoft PowerPoint Template Files)

Remove PDF Metadata

(Portable Document Format)

Remove OTF Metadata

(OpenType Font)

Remove ODT Metadata

(OpenDocument Text File Format)

Remove ODS Metadata

(OpenDocument Spreadsheet)

Remove MSG Metadata

(Outlook Message Item File)

Remove MPT Metadata

(Microsoft Project Template)

Remove MPP Metadata

(Microsoft Project File)

Remove MP3 Metadata

(MP3 Audio File)

Remove MOV Metadata

(Apple QuickTime Movie)

Remove JPF Metadata

(JPEG 2000 Image)

Remove JPEG Metadata

(Joint Photographic Expert Group Image)

Remove JP2 Metadata

(JPEG 2000 Core Image)

Remove HEIF Metadata

(High Efficiency Image Format)

Remove HEIC Metadata

(High Efficiency Image Format)

Remove GIF Metadata

(Graphical Interchange Format)

Remove FLV Metadata

(Flash Video File)

Remove EPUB Metadata

(Open eBook File)

Remove EML Metadata

(E-Mail Message)

Remove EMF Metadata

(Enhanced Metafile Format)

Remove DXF Metadata

(Autodesk Drawing Exchange Format)

Remove DWG Metadata

(AutoCAD Drawing File)

Remove DOTX Metadata

(Microsoft Word Template File )

Remove DOTM Metadata

(Microsoft Word 2007+ Template File)

Remove DOT Metadata

(Microsoft Word Template Files)

Remove DOCX Metadata

(Office 2007+ Word Document)

Remove DOCM Metadata

(Microsoft Word 2007 Marco File)

Remove DOC Metadata

(Microsoft Word Binary Format)

Remove DJVU Metadata

(Graphics File Format)

Remove DICOM Metadata

(Digital Imaging and Communications in Medicine)

Remove DCM Metadata

(DICOM Image)

Remove BMP Metadata

(Bitmap Image File)

Remove AVI Metadata

(Audio Video Interleave File)

Remove ASF Metadata

(Advanced Systems Format File)

Remove MKV Metadata

(Matroska Video File)

Remove ONE Metadata

(OneNote Document)

Remove DJVU Metadata

(Graphics File Format)

Back to top
 English