Partager via


DisableEncode Property

Enables or disables base64 or hexBinary encoding for Memo (Binary) or Character (Binary) fields.

Setting DisableEncode at the XMLAdapter level sets the default DisableEncode values for XMLField objects when they are created and added to the Fields collection by the following XMLAdapter methods:

Additionally, changing DisableEncode at the XMLAdapter level affects only the next set of XMLField objects created, not the existing XMLField objects in the Fields collection. Therefore, to modify the setting of DisableEncode for an existing XMLField object, change the value at the XMLField level.

Object.DisableEncode [= lValue]

Property Values

  • lValue
    Logical data type. The following table lists the values for lValue.
    lValue Description
    False (.F.) Disable base64 or hexBinary encoding for Memo (Binary) or Character (Binary) fields. (Default)
    True (.T.) Enable base64 or hexBinary encoding for Memo (Binary) or Character (Binary) fields.

Remarks

Visual FoxPro disregards invalid characters or incorrect length in base64 and hexBinary encoded strings.

If XMLAdapterDisableEncode is True (.T.) when the LoadXML method is executed, the XMLFieldMaxLength property is set to the maximum length for the encoded data. Otherwise, Visual FoxPro uses the original MaxLength value.

If XMLAdapterDisableEncode is True (.T.) when the ToXML method is executed, the xsd:maxLength value in the XML Schema Definition (XSD) schema is set to the maximum length for the decoded data. Otherwise, Visual FoxPro uses the value of the XMLFieldMaxLength property.

See Also

Properties | XMLAdapter Object Properties, Methods, and Events | XMLField Object Properties, Methods, and Events | Fields Collection (XMLTable) | MaxLength Property | ToXML Method

Applies To: XMLAdapter Class | XMLField Class