複製 Excel 工作表
The code example above shows how to use IronXL to duplicate and copy WorkSheets within and between Excel WorkBooks. 在其他工作簿中複製和貼上工作表。 在同一工作簿中建立重複工作表。
The CopySheet method is used to duplicate a worksheet within the same workbook or spreadsheet. 新工作表的名稱是必要的參數。
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.
你可以透過這個連結下載專案檔。
如何在 C# 中複製 Excel 工作表
- 開啟 Excel 工作簿並建立一個新工作表。
- Use the
CopyTomethod to copy data to the new worksheet. - 儲存新的 Excel 工作表。





