Tag Archives: Formatting Cells and Ranges

How to Use NumberFormat in VBA

Description FormatNumber is a property of the Range object of Excel. The Range object can be considered as a cell or a group of cells — be that a single cell, a column in an Excel table, or the UsedRange of an Excel sheet. The

No Thumbnail

Excel VBA, Vertical Alignment

In this article I will explain the different vertical alignment formattings applicable to cells and ranges. I have also provided the VBA code required to apply them. Jump To: Top, xlTop Center, xlCenter Bottom, xlBottom Justify, xlJustify Distributed, xlDistributed – Top, xlTop: The following code will top align the text in cell “A1”: Range(“A1”).VerticalAlignment = xlTop