Add or Insert a Worksheet

Adding a Worksheet

To add a worksheet using Aspose.Cells.GridDesktop, please follow the steps below:

  1. Add Aspose.Cells.GridDesktop control to a form.
  2. Call the Worksheet collection’s Add method in the GridDesktop control.

Many overloaded versions of the Add method are available. Using the above overloaded version, for example, a worksheet is added to the Excel file with a default sheet name. Using other overloaded versions of the Add method, it is possible to define the name as shown below in the example.

Inserting a Worksheet

To insert a worksheet using Aspose.Cells.GridDesktop, please follow the steps below:

  1. Add the Aspose.Cells.GridDesktop control to a form.
  2. Call the Worksheets collection’s Insert method in the GridDesktop control.