D
Darren Hill
[Excel 2007]
I have a macro that performs operations on a table, based on its current
autofit style, so I need to be able to distnguish between the following
four conditions:
Table currently set to:
* Autofit to Window
* Autofit to Contents
* Fixed Width (all columns equal width)
* Fixed Width (columns have different width)
Actually, differentiating between the last two isn't that important, but
I do need to differentiate between the first three.
I tried using autofitbehavior, but either I'm using it wrong or it can
only be used to set autofit, not read it.
So I scaled back my goal and tried to distinguish between autofit
(either type) and non-autofit, with the following code, but that doesn't
work reliably either.
With tblTable
If .AllowAutoFit = True Then
AutoFit = wdAutoFitWindow
Else
AutoFit = wdAutoFitFixed
End If
End With
Can anyone help out?
Thanks,
Darren
I have a macro that performs operations on a table, based on its current
autofit style, so I need to be able to distnguish between the following
four conditions:
Table currently set to:
* Autofit to Window
* Autofit to Contents
* Fixed Width (all columns equal width)
* Fixed Width (columns have different width)
Actually, differentiating between the last two isn't that important, but
I do need to differentiate between the first three.
I tried using autofitbehavior, but either I'm using it wrong or it can
only be used to set autofit, not read it.
So I scaled back my goal and tried to distinguish between autofit
(either type) and non-autofit, with the following code, but that doesn't
work reliably either.
With tblTable
If .AllowAutoFit = True Then
AutoFit = wdAutoFitWindow
Else
AutoFit = wdAutoFitFixed
End If
End With
Can anyone help out?
Thanks,
Darren