Skip to main content

Format Cells

Excel·v1.11.1
ExcelFormattingWrites files

Set fill, font, borders, alignment, number format and size on a range. Every field is optional and only the ones filled in are changed

Inputs

NameTypeRequiredDefaultDescription
Excel Instance
excelInstance
variableRequired
Sheet Name
sheetName
stringOptionalLeave empty for the first sheet
Range
range
stringOptionalA1:D20, a single cell, whole columns A:C, or empty for everything on the sheet
Fill Colour
fillColor
stringOptionalHex such as #4472C4, or a name such as light green
Font Colour
fontColor
stringOptional
Font
fontName
stringOptionalCalibri, Arial, Georgia
Font Size
fontSize
numberOptional
Bold
bold
booleanOptional
Italic
italic
booleanOptional
Underline
underline
booleanOptional
Horizontal Alignment
horizontalAlignment
enumOptional
leftcenterrightjustifyfill
Vertical Alignment
verticalAlignment
enumOptional
topmiddlebottom
Wrap Text
wrapText
booleanOptional
Indent
indent
numberOptional
Text Rotation
textRotation
numberOptionalDegrees, -90 to 90
Number Format
numberFormat
enumOptional
generalnumbernumber2thousandscurrencypercentpercent2datedatetimetimetextcustom
Currency Symbol
currencySymbol
stringOptional$
Shown when numberFormat = currency
Custom Format Code
customNumberFormat
stringOptionalSuch as #,##0.00 or dd-mmm-yyyy
Shown when numberFormat = custom
Border Style
borderStyle
enumOptional
nonethinmediumthickdotteddasheddouble
Border Colour
borderColor
stringOptional
Shown when borderStyle = thin / medium / thick / dotted / dashed / double
Border Edges
borderEdges
enumOptionalall
alloutlinetopbottomleftright
Shown when borderStyle = none / thin / medium / thick / dotted / dashed / double
Column Width
columnWidth
numberOptional
Row Height
rowHeight
numberOptional

Compatibility

WindowsLinuxAttendedUnattended

Related activities