Resize-to-fit Table Columns (PowerPoint)

I have a table in PowerPoint with several rows and columns of data. I would like to resize selected columns so the width of the column does not exceed the width of the longest data - in otherwords make the column width the perfect fit. I am wondering how I would go abouts in doing this?

Below are my various attempts but they have failed as when I went to run my macro, the column widths did not change.

[code]mySlide.Shapes(mySlide.Shapes.Count).Table.Cell(x, y).Shape.TextFrame.WordWrap = msoFalse
mySlide.Shapes(mySlide.Shapes.Count).Table.Cell(x, y).Shape.TextFrame.AutoSize = ppAutoSizeShapeToFitText[/code]
[code]mySlide.Shapes(mySlide.Shapes.Count).Table.Columns(x).Width = ppAutoSizeShapeToFitText[/code]
[code]mySlide.Shapes(mySlide.Shapes.Count).Table.Cell(targetRow, targetColumn).Shape.TextFrame.AutoSize = ppAutoSizeShapeToFitText[/code]
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!