General information
Category:
Windows API functions
Hi,
In normal, it should be fine to capture Date format from Excel.
What's the cells' format of the date column?
And how you import it in VFP? append from test.xls type xl5.
To import it by manualy, you can:
oExcel=Createobject("EXCEL.APPLICATION")
oBook=oExcel.workbooks.open("file name with full path")
oSheet=oBook.worksheets(1)
** reading cell info. one by one
....
xValue=oSheet.cells(row,col).value
....
oBook.close && must be closed
Release oExcel
Also, look at UT download to see if there are any Excel import library.
:) Wilfred
>I need to import from excel files with a column of dates stored in dd/mm/yyyy format. Unfortunately the first row of cells in each file holds the heading for the columns. If I remove the heading cells from my test spreadsheet it imports fine. If they're left in the date column is imported to a 9 character string field and I loose the last digit of each date.
>
>I think I need to create an excel object and then somehow read in values from the the header cells before deleting them so that dates will import properly.
>
>I'm new to all this though and I'm stuck again. Any help would be greatly appreciated.
>
>Phil.
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only