Information générale
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
>>I'm trying to save an Excel97-file to DBF3 like this:
>>
>>WITH ox.activeworkbook
>> .SaveAs(lcFilename, 8)
>> .saved = .t.
>>ENDWITH
>>
>>The only problem is that some numeric fields are empty in the resulting table and I have no clue why. Most of the values in the same column are correct. Has anybody seen this before? Of course I have tried every trick I know to ensure that data in Excel has correct numeric format but this doesn't seem to be enough.
>
>Check if all the numbers are really saved as numeric. Some may be interpreted as text.
>
>Change the allignment to "General" - a real number is right-alligned in this case.
I changed cell formats to "General" and everything seemed to be OK, but conversion failed again. Then I changed cell format to scientific and EVERYTHING WORKED as expected. To be really scientific I changed back to numeric with 2 decimals and the problem came back. What can we learn from this? There is no way to be sure that numbers in Excel are really numbers except when they are formatted as scientific.
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement