wrecks
10-13-2008, 12:19 PM
I am using Shapes.AddOLEObject to insert Word tables into PowerPoint slides.
I set the font with ...table.Range.Font.Name='Arial'
I fill the cells with ...table.Cell(i,j).Range.Text='1,234'
In some cases, the number of columns in the table varies, and in most cases the width of the content of the cells varies.
My problem: I want to set the font size to be as large as possible while allowing the entire table to fit on the slide.
I know I can change the font size with something like
table.AutoFitBehavior=wdAutoFitContent
table.Range.Font.Size=14
I figure to start with a large font and then iterate smaller until the table fits. But how can I tell if (say) 14 is small enough to make the table fit on the slide?
An example follows in my next post.
I set the font with ...table.Range.Font.Name='Arial'
I fill the cells with ...table.Cell(i,j).Range.Text='1,234'
In some cases, the number of columns in the table varies, and in most cases the width of the content of the cells varies.
My problem: I want to set the font size to be as large as possible while allowing the entire table to fit on the slide.
I know I can change the font size with something like
table.AutoFitBehavior=wdAutoFitContent
table.Range.Font.Size=14
I figure to start with a large font and then iterate smaller until the table fits. But how can I tell if (say) 14 is small enough to make the table fit on the slide?
An example follows in my next post.