SetItalic

function SetItalic(isItalic: boolean = null): void

Description

Sets the italic property to the text characters in the current cell or cell range.

Parameters

isItalicbooleandefault: null

Specifies that the contents of the current cell / cell range are displayed italicized.

Returns

void

Try It

var oWorksheet = Api.GetActiveSheet();
oWorksheet.GetRange("A2").SetValue("Italicized text");
oWorksheet.GetRange("A2").SetItalic(true);
oWorksheet.GetRange("A3").SetValue("Normal text");

Get Help

  • If you have any questions about ONLYOFFICE Docs, try the FAQ section first.
  • You can request a feature or report a bug by posting an issue on GitHub.
  • You can also ask our developers on ONLYOFFICE forum (registration required).