Excel-Arbeitsblätter kopieren

The code example above shows how to use IronXL to duplicate and copy WorkSheets within and between Excel WorkBooks. Blätter in und aus anderen Arbeitsmappen kopieren und einfügen. Erstellen Sie doppelte Blätter innerhalb derselben Arbeitsmappe.

The CopySheet method is used to duplicate a worksheet within the same workbook or spreadsheet. Der Name des neuen Arbeitsblatts ist als Parameter erforderlich.

Use the CopyTo method to duplicate a sheet to or from another workbook. A WorkBook is required as the first parameter and is followed by the name of the new worksheet.

Sie können ein Dateiprojekt von diesem Link herunterladen.

Wie man Excel-Arbeitsblätter in C# kopiert

  1. Installieren Sie eine Excel-Bibliothek, um Arbeitsblätter zu kopieren.
  2. Laden Sie eine Excel-Arbeitsmappe und erstellen Sie ein neues Blatt.
  3. Use the CopyTo method to copy data to the new worksheet.
  4. Speichern Sie das neue Excel-Arbeitsblatt.

Erfahren Sie, wie man Excel-Zellen mit C# und IronXL kopiert.

Bereit anzufangen?
Nuget Downloads 1,765,830 | Version: 2025.12 gerade veröffentlicht