Hi Perry ---
You could create an Excel sheet and write each row of data via OLE Automation if you really wanted to but it may be easier to use the COPY TO ...TYPE XLS combo to create the file then use automation to open it:
oExcel=CREATEOBJECT("Excel.Application")
oExcel.Workbooks.Open("NewXLSFile.XLS")
Now do whatever you would like to it. Look at VBA Help in Excel. VBA syntax for manipulating Excel stuff is not all that different than VFP.
>
>This is my 1st attempt at OLE Automation. I have a table from a x-tab query that I would like to transfer to an Excel worksheet for viewing, maybe even create a report with Text and company logo. I'm a little confused, do I use CREATEOBJECT('Excel.sheet') and export the data to the worksheet?? VFP help is a little vague in the matter.
>
>TIA
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05