我试图通过vba自动调整word中的表格内容,但是当使用autofit时,列会缩小到合适的大小,但是表的大小也会缩小。如何使桌子的宽度保持在最大限度?
代码:
With tableEmployees
.AllowAutoFit = True
.AutoFitBehavior wdAutoFitWindow
.Columns(1).AutoFit
.Columns(2).AutoFit
.Columns(3).AutoFit
.Columns(4).AutoFit
End With
表结构:
id | name | phone |