Sytze,

On 11/05/2014 04:05 PM, Sytze de Boer wrote:
I thought Craig's work would be the last word with this problem, but I
could not get it to work on many occasions.

What problems did you have?  It has always worked for me.

Then I came across Jun Tangunan's solution

create cursor junk (name c(10), age i, address c(20))
local lcfile
lcfile = getfile("xlsx")
loexcel = createobject("excel.application")

This depends on Excel being installed on the target machine. Albeit Craig's solution requires the OLE stuff be installed, at least that's a free install.

loexcel.workbooks.open(lcfile)
loexcel.activeworkbook.saveas("c:\test.xls",39)
loexcel.activewindow.close(.t.)
loexcel.quit
append from c:\test.xls type xls && or xl5
browse normal
close databases all

This seems to work for me, every time


It would fail on spreadsheets bigger than the 65,000 odd rows that was the limit in older versions.

--

Frank.

Frank Cazabon


_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/[email protected]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to