Get the column width of a cell

=columnsize() is the column width of the active cell @

=columnsize(A1) is the column width of cell A1



Function ColumnSize(Optional Cell As Variant)
 If IsMissing(Cell) Then
  ColumnSize = ActiveCell.ColumnWidth
 Else
  ColumnSize = Cell.ColumnWidth
 End If
End Function



© Copyright andrewsexceltips.net All Rights Reserved.