Returns or sets a value that determines the alignment of data in a cell or range of selected cells. Not available at design time.
object.CellAlignment [= value ]
The CellAlignment property syntax has these parts:
| Part | Description |
|---|---|
| object | An object expression that evaluates to an object. |
| value | An integer specifying how text should be aligned within cells, as described in Settings. |
The settings for value are:
| Value | Description |
|---|---|
| 0 | Left Top |
| 1 | Left Center (default for strings) |
| 2 | Left Bottom |
| 3 | Center Top |
| 4 | Center Center |
| 5 | Center Bottom |
| 6 | Right Top |
| 7 | Right Center (default for numbers) |
| 8 | Right Bottom |
| 9 | General: Left Center for strings, Right Center for numbers |