PowerPoint Generator API
  • PowerPoint Generator API
  • Getting started
    • Quick start
  • API reference
    • token/create
    • generator/create
  • Knowledge base
    • Key concepts
    • Templating your presentation
    • Building your JSON payload
    • Finding shape names
  • JSON/ PPTX Reference
    • presentation
    • slides
    • shapes
      • textbox
      • chart
      • picture
      • table
    • tags
    • Deprecated
  • Examples
    • Presentation
      • Naming output presentation
      • Using multiple templates
    • Slide
      • Change shape size and position
      • Change shape background color
      • Hide or remove shape
      • Replacing tags
    • Textboxes
      • Add text
      • Set font type and size
      • Set font color and font background color
      • Set bold, italic & underline
      • Set text alignment
      • Set text indentation
      • Set text line spacing
      • Using bullet-points
    • Chart
      • Change font settings
      • Insert data
      • Adjust chart legend
      • Appending to data labels
    • Pictures
    • Table
      • Populate simple table
      • Using `text_runs` in Table cells
      • Handling merged cells
      • Update a specific cells in existing table
    • Tags
Powered by GitBook
On this page

Was this helpful?

  1. Examples
  2. Table

Update a specific cells in existing table

How to update a specific cells without editing existing cells

PreviousHandling merged cellsNextTags

Last updated 10 months ago

Was this helpful?

Sometimes, you may need to retain the content of an existing table while modifying specific cells. To achieve this, use the keyword null to skip the cells you don't want to change.

In the example below, we updated the cell value in row 2, column 3 from 70% to NA, and added a new row with data for FIAT. All other cells remain unchanged.

Before vs after

Template Presentation

JSON Payload

{
    "presentation": {
        "template": "Table-Shape-New-Data.pptx",
        "export_version": "Pptx2013",
        "slides": [
            {
                "type": "slide",
                "slide_index": 0,
                "shapes": [
                    {
                        "name": "Mytable",
                        "data_cells": [
                            [
                                null,
                                null,
                                null,
                                null
                            ],
                            [
                                null,
                                null,
                                "NA",
                                null
                            ],
                            [
                                null,
                                null,
                                null,
                                null
                            ],
                            [
                                null,
                                null,
                                null,
                                null
                            ],
                            [
                                "FIAT",
                                "30%",
                                "40%",
                                "50%"
                            ]
                        ]
                    }
                ]
            }
        ]
    }
}
4MB
Table-Shape-New-Data.pptx