Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Date problems when importing excel files.
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00312458
Message ID:
00312661
Vues:
15
I have not tried this, but could you fix that date as opposed to creating an exception file????

>Hi John,
>
>>Regardless, there is nothing preventing you from catching this in your import routine, unless of course, you are relying on Append From x Type XLS....
>>
>>If you are, you will need to use Automation Techniques instead, so you can fix the values...
>>
>
>This is not true. You can validate data in an append from command by using a UDF:
>
Append from myfile.xls type xls for IsValidDate()
>
>*IsValidDate.prg
>
>if myDateField > {^1900/1/1} && or whatever test you need to validate
>  * Return .T. and record will be appended
>  llAppendIt = .t.
>else
>  * Log/handle exception
>  * ...
>  * Return .F. and the record will not be appended
>  llAppendIT = .f.
>endif
>
>return llAppendIt
>
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform