Skip to main content

Таблица DocumentAPI.ScientificCellFormatting

Таблица содержит параметры для экспоненциального формата ячеек таблицы. Данная таблица используется в качестве аргумента метода Cell:setFormat().

ПолеТипОписание
ScientificCellFormatting.decimalPlacesnumberКоличество десятичных позиций
ScientificCellFormatting.minExponentDigitsnumberМинимальное количество позиций экспоненты

Пример​


local table = document:getBlocks():getTable(0)
local cell = table:getCell("B2")

local scientificCellFormatting = DocumentAPI.ScientificCellFormatting()
scientificCellFormatting.decimalPlaces = 2
scientificCellFormatting.minExponentDigits = 3

cell:setFormat(scientificCellFormatting)
print(cell:getFormattedValue())