Add sheet Version 1 (Python)

Action group: Office


Description

The action adds a new sheet to the document

Action icon

Settings of parameters

PropertyDescriptionTypeFilling exampleMandatory field
Parameters
ContextAction context for ods/xlsx documentRobin.OpenSheetD oc
Yes
New sheet nameThe name of the new sheet to be created. It will be added after the active one. The new sheet will become the active sheetRobin.String
No

Special conditions of use

None.

Example of use

Task 

There is a document called Test with one sheet - Sheet 1. You need to add a new sheet and name it Sheet 2. 

Solution

Use the actions "Open", "Add sheet", "Save". 

Implementation

  1. Assemble a robot scheme consisting of actions:
     



  2. Set the "Path to file" parameter for the "Open" action. 

      

  3. Set parameters for the "Add sheet" action. In the "Context" field specify the open context of the document, in the "New sheet name" field the value "Sheet 2". 
  4. Set the parameter for the "Save" action. Specify the context of the Excel document in the Context parameter. 

  5. Launch the robot using the "Start" button in the top panel.

Result

The program robot completed successfully.

A new sheet named "Sheet 2" has been successfully added to the document. 


 

  • Нет меток