>Importing data from Excel, I have some problems:
>
>The prg attempts to sensibly rename the A B C etc Excel fields using a record selected by the user in the file i.e. with the field names. Follwing this, we often get:
>
>1. Truncation of character fields
>2. Strange behaviour of data in the DBF e.g. if you trim the data to remove leading spaces, it truncates to one character; inclusion of certain characters (Excel print features perhaps) that cause the data to disappear when selected. I am using the IMPORT FROM command type XL8.
>Any comments appreciated ... Denis
Denis,
If this works you should tell Brasil not to be though vs us :)
#define xlDBF3 8
oExcel = CreateObject('Excel.Application')
with oExcel
.Workbooks.Open(lcXLSFileName)
.ActiveWorbook.SaveAs(lcDBFName, xlDBF3)
.Quit
endwith
Cetin