>When using VFP to create an Excel file through Office Automation, how do you programically "automatically" adjust the column widths to the longest piece of data in each column? In other words, I want to accomplish the same thing I can do with a mouse by double clicking the Excel A/B/C column header bar column dividing lines when the mouse changes to a spliter icon.
>
>Thanks,
>Robert
NOT TESTED!!!
oExcel.Activeworkbook.Cells.Select()
oExcel.Activeworkbook.Cells.EntireColumn.AutoFit()
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.