Skip to end of banner
Go to start of banner

excelSetCurrentSheet

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

Description

Specifies the current sheet by name or index that subsequent processes should use.

Parameters

Return Type

Boolean

Returns true if the operation was successful, false otherwise.

Example

Add a new row and data to an existing workbook.

use "excel";
int fid = openWorkbook("snakes.xlsx");
setCurrentSheet(fid, "Venemous Snakes");
addRow(fid, 1);
setCurrentSheet(fid, "Non-Venemous Snakes");
addRow(fid, 1);
closeWorkbook(fid);

Result: A new row is first added to the Venemous Snake sheet then a new row is added to the Non-Venemous Snake sheet.

Click here to download the workbook used in this example.

See also

We've encountered an issue exporting this macro. Please try exporting this page again later.
  • No labels