Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Xmltocursor()
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Visual FoxPro et .NET
Titre:
Divers
Thread ID:
00606644
Message ID:
00606693
Vues:
25
>hi....i using ADO.NET's dataset to write data into a XML file, later when i use Visual FoxPro XMLTOCURSOR() function to convert it into cursor, something goes wrong....the integer 0 in dataset become 'F' in cursor and integer 1 in dataset become 'T' in cursor...how do i solve this problem? pls help me.......


By default, VFP scans the data to make a "best quess" as to the type of data in each field. If it only finds "0"s and "1"s in a particular field, it assumes it's logical and converts 0s to .f. and 1's to .t.

To prevent VFP from making a "best guess", create a scheme for the XML so when you bring it in with XMLTOCURSOR, VFP can look at the schema and know that without a doubt, the field you are having a problem with is "Numeric" and not "Logical".

Cathy
Cathy Pountney, Microsoft Visual FoxPro MVP
Memorial Business Systems, Inc. (www.mbs-intl.com)

My Website: (www.frontier2000.com)
My Blog: (www.cathypountney.blogspot.com)
My Book: The Visual FoxPro Report Writer - Pushing it to the Limit and Beyond
Free MSDN Article: What's New in the VFP 9.0 Report Writer
Free MSDN Article: The VFP 9.0 Report Writer In Action
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform