Skip to content

excel shape add

zmworm edited this page Apr 8, 2026 · 48 revisions

Excel: Shape - add

Insert a shape or textbox into a worksheet.

Type: shape, textbox Parent: /{SheetName}

Properties

Property Required Default Description
text No - Text content (supports \n for line breaks)
name No auto Shape name
font No - Font typeface
size No - Font size in pt
bold No false Bold text
italic No false Italic text
color No - Font color (hex)
fill No - Fill color (hex) or "none" for transparent
line No - Line/border color (hex) or "none"
align No left Text alignment: left, center/c/ctr, right/r
shadow No - Shadow effect
glow No - Glow effect
reflection No - Reflection: tight/small, half/true, full, or percentage
softedge No - Soft edge radius in pt
margin No - Text margin in pt
x No 1 Column offset
y No 1 Row offset
width No 5 Column span
height No 3 Row span

Note: When fill=none, effects (shadow, glow, reflection, softedge) apply to text runs instead of the shape.

Examples

officecli add data.xlsx /Sheet1 --type shape --prop text="Hello World" --prop fill=4472C4 --prop color=FFFFFF
officecli add data.xlsx /Sheet1 --type textbox --prop text="Transparent note" --prop fill=none --prop shadow=true

See Also


Based on OfficeCLI v1.0.38

Clone this wiki locally