Hi Marc,
I use OLE Automation - open the template, save it to a new name and then walk through the cursor putting the data into the template.
If the cursor is large and the formatting relatively light, you can do the same thing in reverse: Open a new Excel file from the cursor and then format the columns, add column titles and save. This technique means you'll need to put the formatting into the VFP program instead of onto the Excel template file, so it couldn't be upgraded without updating the VFP program.
Either way is quick and accurate.
HTH
Barbara
>I have data in a VFP cursor and want to create an Excel file with it.
>I used the COPY TO command but I also want to use a formatted Excel template.
>Someone knows the easiest way to do that? Thank you in advance.